Uploaded image for project: 'Apache Roller'
  1. Apache Roller
  2. ROL-2065

Gaurav sometimes displaying empty summary as unresolved "$entry.summary"

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 5.1.1
    • Fix Version/s: 5.1.2
    • Component/s: Themes and Macros
    • Labels:
      None

      Description

      day.vm in Gaurav checks existence of summary in following code:

      #if($entry.summary != "")
          <p>$entry.summary</p>
          <a class="btn btn-primary" href="$url.entry($entry.anchor)">Read More <i class="icon-angle-right"></i></a>
      #else
          <p>$entry.displayContent</p>
      #end
      

      I experienced WEBLOGENTRY.SUMMARY went null accidentally (https://twitter.com/lbtc_xxx/status/549181370908430338). in such case, Gaurav thinks the summary is exist and render it as "$entry.summary". I don't know how summary went null, but the db schema allows null so I guess changing comparison logic to more safer one (use $utils.isNotEmpty() instead) is reasonable.

        Attachments

        1. ROL-2065.patch
          0.6 kB
          Kohei Nozaki

          Activity

            People

            • Assignee:
              djohnson David Johnson
              Reporter:
              xkylex Kohei Nozaki
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: