JakobKrainz avatar JakobKrainz committed b2578e2

bugfix

Comments (0)

Files changed (1)

                 accessdict[path][p].setdefault(a, [])        
 
     def setAccessHelper(accessdict, path, prefix, ats, realname):
+        # debug(">>> " + path+ " " + prefix + " " + realname + " -> " + ats)
         initDfl(accessdict, path)
         if ats == 'r':
             accessdict[path][prefix]["read"].append(realname)
 
     accessdict = {}
     for item in accessContent.sections():
+        # debug(">> section " + item)
         if len(item) >= 1 and item[0] == '/':
             path = item
-            for userorgroup, accesstype in accessContent.items(path):
+            for userorgroup, accesstype in accessContent.items(item):
                 if userorgroup[0] == '@':
                     prefix = 'group'
                     realname = userorgroup[1:]
         elif len(item) >= 1 and item in userlist:
             prefix = "user"
             realname = item
-            for path, accesstype in accessContent.items(path):
+            for path, accesstype in accessContent.items(item):
                 ats = accesstype.strip()
                 setAccessHelper(accessdict, path, prefix, ats, realname)
         elif len(item) >= 1 and item[0] == '@' and item[1:] in groupdict:
             prefix = "group"
             realname = item[1:]
-            for path, accesstype in accessContent.items(path):
+            for path, accesstype in accessContent.items(item):
                 ats = accesstype.strip()
                 setAccessHelper(accessdict, path, prefix, ats, realname)
         else:
-            warn("access file section [%s]: invalid name" % path)            
+            warn("access file section [%s]: invalid name" % item)
     return accessdict
 
 def parse_config(confdir):
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.