Commits

Joseph Tate committed 86fe338

If the expires_time is null

Comments (0)

Files changed (1)

c5t/news/templates/all_news.mak

     <tr>
       <td>${news_item.title}</td>
       <td>${news_item.slug}</td>
-      <td>${news_item.created_datetime.strftime('%b %d %y')}<br/>${news_item.created_datetime.strftime('%I:%M %P')}</td>
-      <td>${news_item.expires_datetime.strftime('%b %d %y')}<br/>${news_item.expires_datetime.strftime('%I:%M %P')}</td> 
+      <td>${news_item.created_datetime.strftime('%b %d %y') if news_item.created_datetime else 'Never'}<br/>${news_item.created_datetime.strftime('%I:%M %P') if news_item.created_datetime else 'Never'}</td>
+      <td>${news_item.expires_datetime.strftime('%b %d %y') if news_item.expires_datetime else 'Never'}<br/>${news_item.expires_datetime.strftime('%I:%M %P') if news_item.expires_datetime else ''}</td> 
       <td>
       <div class="tagHandler">
             <ul id="tagHandler" class="tagHandler tagHandlerContainer">
   </table>
 %else:
   No news entries.
-%endif
+%endif