mirror of
https://github.com/bitwarden/server.git
synced 2025-04-06 13:38:13 -05:00
Return not support extension messages
This commit is contained in:
parent
b3b0bfa221
commit
86aa342bad
@ -49,6 +49,11 @@ namespace Bit.Api.Utilities
|
||||
errorModel.Message = exception.Message;
|
||||
context.HttpContext.Response.StatusCode = 400;
|
||||
}
|
||||
else if(exception is NotSupportedException && !string.IsNullOrWhiteSpace(exception.Message))
|
||||
{
|
||||
errorModel.Message = exception.Message;
|
||||
context.HttpContext.Response.StatusCode = 400;
|
||||
}
|
||||
else if(exception is ApplicationException)
|
||||
{
|
||||
context.HttpContext.Response.StatusCode = 402;
|
||||
|
Loading…
x
Reference in New Issue
Block a user