]> git.llucax.com Git - software/pymin.git/blobdiff - pymin/services/proxy/__init__.py
fix command names
[software/pymin.git] / pymin / services / proxy / __init__.py
index 2740cc8c8ab0f8d546cf6b8986d19bb37d825b17..54ff3797eb5db436662cf3488c446663687fffb2 100644 (file)
@@ -98,12 +98,14 @@ class UserHandler(Handler):
 
     def __init__(self, users):
         self.users = users
-
+       
+    @handler('Adds a user')
     def add(self, user, password):
         if user in self.users:
             raise UserAlreadyExistsError(user)
         self.users[user] = crypt.crypt(password,'BA')
-
+    
+    @handler('Deletes a user')
     def delete(self, user):
         if not user in self.users:
             raise UserNotFound(user)
@@ -156,4 +158,4 @@ if __name__ == '__main__':
     px.host.delete('192.168.0.25.27')
     px.user.add('lala','soronga')
     px.user.add('culo','sarasa')
-    px.commit()
\ No newline at end of file
+    px.commit()