Allow to hide menus with globals permissions. Fix: 940

This commit is contained in:
joker-x 2020-08-27 19:48:15 +02:00
parent 613a6fb1f0
commit ead7bbf9dd
3 changed files with 33 additions and 22 deletions

View file

@ -40,7 +40,8 @@ async function getAuthenticatedConfig(context) {
user: {
id: context.user.id,
username: context.user.username,
namespace: context.user.namespace
namespace: context.user.namespace,
admin: (config.roles.global[context.user.role]["admin"] || false)
},
globalPermissions,
editors: config.editors,