Meteor-Community-Packages/meteor-roles

Add new function to change scope of existing role assignment

Open

#382 aperta il 15 ott 2023

Vedi su GitHub
 (1 commento) (0 reazioni) (0 assegnatari)JavaScript (161 fork)batch import
enhancementgood first issue

Metriche repository

Star
 (919 star)
Metriche merge PR
 (Nessuna PR mergiata in 30 g)

Descrizione

Add a new function that would accept userId, targetRole and newScope which would then go and change the scope of the assigned role to the newScope. Right now if I want to just change scope I need to remove role and then add it again. For use cases where user can be assigned the same role into multiple scopes, the function should fail if it finds more than one results or have an optional parameter to define the previous scope.

Thoughts?

Guida contributor