mirror of
https://github.com/jlu5/PyLink.git
synced 2025-01-11 12:42:34 +01:00
permissions: apply add/removeDefaultPermissions on the right list
This commit is contained in:
parent
f890ddac1b
commit
6af8e77ee1
@ -34,16 +34,16 @@ def resetPermissions():
|
||||
def addDefaultPermissions(perms):
|
||||
"""Adds default permissions to the index."""
|
||||
with permissions_lock:
|
||||
global permissions
|
||||
global default_permissions
|
||||
for target, permlist in perms.items():
|
||||
permissions[target] |= set(permlist)
|
||||
default_permissions[target] |= set(permlist)
|
||||
|
||||
def removeDefaultPermissions(perms):
|
||||
"""Remove default permissions from the index."""
|
||||
with permissions_lock:
|
||||
global permissions
|
||||
global default_permissions
|
||||
for target, permlist in perms.items():
|
||||
permissions[target] -= set(permlist)
|
||||
default_permissions[target] -= set(permlist)
|
||||
|
||||
def checkPermissions(irc, uid, perms, also_show=[]):
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user