diff --git a/library/constants.php b/library/constants.php index 5d638ed0f..f6558ba55 100644 --- a/library/constants.php +++ b/library/constants.php @@ -415,6 +415,8 @@ ]; // This has to be identical to the rolesMapping in the Auth0 dynamic-permissions script +// WARNING: If you add elements here, you need to make sure they're part of the permissions +// registered in Auth0! $rolesToActions = [ 'boxtribute_god' => [ 'be_god', diff --git a/library/lib/auth0.php b/library/lib/auth0.php index ee059bc0e..021894b78 100644 --- a/library/lib/auth0.php +++ b/library/lib/auth0.php @@ -544,6 +544,8 @@ function updateRolePermissions($roleId, $resourseServerIdentifier, $methods) return $res; } + // If this fails with a 404, it's very likely that some of the submitted + // permissions are not actually registered as permissions in Auth0 throw new Exception($response->getReasonPhrase(), $response->getStatusCode()); }