1
0
Fork 0
forked from github/pelican

ruff UP031 in files: use format specifiers instead of percent format

This commit is contained in:
boxydog 2024-06-01 16:00:17 -05:00
commit 30bde3823f
12 changed files with 47 additions and 50 deletions

View file

@ -537,9 +537,9 @@ class ArticlesGenerator(CachingGenerator):
"""Generate direct templates pages"""
for template in self.settings["DIRECT_TEMPLATES"]:
save_as = self.settings.get(
"%s_SAVE_AS" % template.upper(), "%s.html" % template
f"{template.upper()}_SAVE_AS", f"{template}.html"
)
url = self.settings.get("%s_URL" % template.upper(), "%s.html" % template)
url = self.settings.get(f"{template.upper()}_URL", f"{template}.html")
if not save_as:
continue