From 3b6c1e56c482523d43991a4d117f586f11d24925 Mon Sep 17 00:00:00 2001 From: James Lu Date: Wed, 16 Aug 2017 11:21:06 -0700 Subject: [PATCH] launcher: move reset_permissions() call into the permissions module --- coremods/permissions.py | 3 +++ launcher.py | 2 -- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/coremods/permissions.py b/coremods/permissions.py index f150627..9ad2504 100644 --- a/coremods/permissions.py +++ b/coremods/permissions.py @@ -83,3 +83,6 @@ def check_permissions(irc, uid, perms, also_show=[]): raise utils.NotAuthorizedError("You are missing one of the following permissions: %s" % (', '.join(perms+also_show))) checkPermissions = check_permissions + +# Reset our permissions list on startup. +reset_permissions() diff --git a/launcher.py b/launcher.py index 4507f8c..9014e91 100644 --- a/launcher.py +++ b/launcher.py @@ -110,5 +110,3 @@ def main(): world.started.set() log.info("Loaded plugins: %s", ', '.join(sorted(world.plugins.keys()))) - - coremods.permissions.reset_permissions() # XXX we should probably move this to run on import