1
0
Fork 0
forked from github/pelican

Get Content._summary from metadata

This commit is contained in:
Charles Flèche 2018-02-09 10:40:47 +01:00
commit 06fd9be1c2

View file

@ -337,8 +337,8 @@ class Content(object):
This is based on the summary metadata if set, otherwise truncate the
content.
"""
if hasattr(self, '_summary'):
return self._update_content(self._summary, siteurl)
if 'summary' in self.metadata:
return self.metadata['summary']
if self.settings['SUMMARY_MAX_LENGTH'] is None:
return self.content