Closed Slavrix closed 4 years ago
Isn't this covered by the setting onlyScoped
, added in version 3.2.0?
Probably helps if I read things fully right..... :D
On Sun, 16 Feb. 2020, 4:19 pm Simon Schick, notifications@github.com wrote:
Isn't this covered by the setting onlyScoped?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Meteor-Community-Packages/meteor-roles/issues/313?email_source=notifications&email_token=ACVUD7Z3AX5JQYMQQVFYDLTRDDEG3A5CNFSM4KV6TNB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEL36DQY#issuecomment-586670531, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACVUD7523UQO72NFEOBFNSTRDDEG3ANCNFSM4KV6TNBQ .
It would be useful to extend the getRolesForUser method to allow for it to return roles for the scope only, if a scope is provided.
currently if you provide a scope, it returns an array that includes the roles for that scope AND the global scope.
Use Case: Administrators of a Scope are allowed to create their own roles/permissions and name them what they choose. We don't want the Scope Admins to be able to view global roles that are included by developers. eg super administrators, vip users, early adoptor flags etc.