Skip to content

Commit

Permalink
Allow fileRules for root content.json
Browse files Browse the repository at this point in the history
  • Loading branch information
purplesyringa committed Jun 13, 2017
1 parent 742c2fe commit 67395b5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/Content/ContentManager.py
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,12 @@ def getRules(self, inner_path, content=None):
if not file_info:
return False # File not found
inner_path = file_info["content_inner_path"]

if inner_path == "content.json": # Root content.json
rules = {}
rules["signers"] = self.getValidSigners(inner_path, content)
return rules

dirs = inner_path.split("/") # Parent dirs of content.json
inner_path_parts = [dirs.pop()] # Filename relative to content.json
inner_path_parts.insert(0, dirs.pop()) # Dont check in self dir
Expand Down

0 comments on commit 67395b5

Please sign in to comment.