add custom exceptions and start using them in every service
This commit is contained in:
parent
7bff14a66e
commit
eb271793ad
4 changed files with 33 additions and 2 deletions
|
|
@ -0,0 +1,10 @@
|
|||
namespace SurveyBackend.Services.Exceptions;
|
||||
|
||||
public class UnauthorizedException : ServiceException
|
||||
{
|
||||
public override int StatusCode => 401;
|
||||
|
||||
public UnauthorizedException(string message) : base(message)
|
||||
{
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue