mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
generators: Use the static format to read Static metadata
This cuts down on the remaining difference between static files and articles/pages. The main difference is that path-based metadata is now parsed for static content.
This commit is contained in:
parent
f147d9ec4a
commit
29cdb37af3
2 changed files with 10 additions and 7 deletions
|
|
@ -347,7 +347,7 @@ def read_file(path, fmt=None, settings=None):
|
|||
metadata.update(reader_metadata)
|
||||
|
||||
# eventually filter the content with typogrify if asked so
|
||||
if settings and settings.get('TYPOGRIFY'):
|
||||
if content and settings and settings.get('TYPOGRIFY'):
|
||||
from typogrify.filters import typogrify
|
||||
content = typogrify(content)
|
||||
metadata['title'] = typogrify(metadata['title'])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue