C#C
C#11mo ago
ThangBoc

BL - UserManager custom role

Let's say when registering a new user to the web api. For my use case (since I am doing role based access priority) I need to create a default role "User" I wonder how it is done normally.

I am thinking about doing it directly inside the program.cs in the server side

In my last project I did it like this hardcode alongside admin user
Was this page helpful?