From fd085d2d371023d37e91d53c8f7357348ba836b1 Mon Sep 17 00:00:00 2001 From: shortcutme Date: Mon, 29 Apr 2019 16:54:07 +0200 Subject: [PATCH] Rev4086, Fix verify content.json files without files_optional --- src/Config.py | 2 +- src/Content/ContentManager.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Config.py b/src/Config.py index a2d306c5..f8f2d544 100644 --- a/src/Config.py +++ b/src/Config.py @@ -13,7 +13,7 @@ class Config(object): def __init__(self, argv): self.version = "0.7.0" - self.rev = 4085 + self.rev = 4086 self.argv = argv self.action = None self.pending_changes = {} diff --git a/src/Content/ContentManager.py b/src/Content/ContentManager.py index ad3f70e1..f9eca61b 100644 --- a/src/Content/ContentManager.py +++ b/src/Content/ContentManager.py @@ -151,7 +151,7 @@ class ContentManager(object): deleted, renamed = self.getFileChanges(old_files, new_files) for relative_path_old, relative_path_new in renamed.items(): - if relative_path_new in new_content.get("files_optional"): + if relative_path_new in new_content.get("files_optional", {}): self.optionalRenamed(content_inner_dir + relative_path_old, content_inner_dir + relative_path_new) if self.site.storage.isFile(relative_path_old): try: @@ -1032,4 +1032,4 @@ class ContentManager(object): return done def optionalRenamed(self, inner_path_old, inner_path_new): - return True \ No newline at end of file + return True