Commits

Marcin Kuzminski committed 6f8f1ab

fixes issue when owner of a repo couldn't revoke permissions for users and groups

  • Participants
  • Parent commits 9e53425
  • Branches default

Comments (0)

Files changed (1)

rhodecode/controllers/admin/repos.py

 
 from rhodecode.lib import helpers as h
 from rhodecode.lib.auth import LoginRequired, HasPermissionAllDecorator, \
-    HasPermissionAnyDecorator
+    HasPermissionAnyDecorator, HasRepoPermissionAllDecorator
 from rhodecode.lib.base import BaseController, render
 from rhodecode.lib.utils import invalidate_cache, action_logger, repo_name_slug
 from rhodecode.lib.helpers import get_token
 
         return redirect(url('repos'))
 
-    @HasPermissionAllDecorator('hg.admin')
+
+    @HasRepoPermissionAllDecorator('repository.admin')   
     def delete_perm_user(self, repo_name):
         """
         DELETE an existing repository permission user
                     category='error')
             raise HTTPInternalServerError()
 
-    @HasPermissionAllDecorator('hg.admin')
+    @HasRepoPermissionAllDecorator('repository.admin')
     def delete_perm_users_group(self, repo_name):
         """
         DELETE an existing repository permission users group