Refactor the AdminOnly authorization policy to handle cases where a user profile is not found. Instead of throwing a NotFoundException, it now throws a ForbiddenException, ensuring a more appropriate response for unauthorized access attempts. Also introduces PolicyConstants for policy names. |
||
---|---|---|
.. | ||
AdminOnlyRequirement.cs | ||
PolicyConstants.cs |