This commit is contained in:
j 2016-08-31 19:07:44 +02:00
parent 1c580a2df7
commit 0f0f5f42d8

View file

@ -237,6 +237,7 @@ def get_ui(user_ui, user=None):
ui = {} ui = {}
config = copy.deepcopy(settings.CONFIG) config = copy.deepcopy(settings.CONFIG)
ui.update(config['user']['ui']) ui.update(config['user']['ui'])
def update_ui(ui, new): def update_ui(ui, new):
''' '''
only update set keys in dicts only update set keys in dicts
@ -390,7 +391,6 @@ def has_capability(user, capability):
return level in settings.CONFIG['capabilities'][capability] \ return level in settings.CONFIG['capabilities'][capability] \
and settings.CONFIG['capabilities'][capability][level] and settings.CONFIG['capabilities'][capability][level]
def merge_users(old, new): def merge_users(old, new):
old.annotations.all().update(user=new) old.annotations.all().update(user=new)
old.edits.all().update(user=new) old.edits.all().update(user=new)