Closed gazzer82 closed 9 years ago
Sorry being an idiot, removing the var from Roles fixed it.
@gazzer82, careful with the use of that variable. If you use Roles
as your own variable then you are overwriting the Roles
variable which gives access to the roles
package. :-)
I am trying to get an array of the Roles a user belongs to, and failing miserably.
I have tried the following call, both on the client and the server:
But i always get the following error:
I have tried passing in both a user object and users ID and neither seem to work, i have checked with Node Inspector and both the user object and the userID are valid and not null when the Role.getRolesForUser is called.
Any help greatly appreciated.
Gareth