--- a/src/mercurialserver/ruleset.py Tue Sep 06 11:00:24 2011 +0100
+++ b/src/mercurialserver/ruleset.py Tue Sep 06 11:02:31 2011 +0100
@@ -35,7 +35,7 @@
class Ruleset(object):
'''Class representing the rules in a rule file'''
-
+
levels = ["init", "write", "read", "deny"]
def __init__(self):
@@ -44,7 +44,7 @@
def set(self, **kw):
self.preset.update(kw)
-
+
def get(self, k):
return self.preset.get(k, None)
@@ -62,7 +62,7 @@
if a <= levelindex:
return True
return False
-
+
def readfile(self, fn):
f = open(fn)
try:
@@ -76,10 +76,9 @@
ix = self.levels.index(l[0])
else:
ix = len(self.levels)
- self.rules.append((ix,
+ self.rules.append((ix,
rule([c.split("=", 1) for c in l[1:]])))
finally:
f.close()
rules = Ruleset()
-