mirror of
https://github.com/elyby/oauth2-server.git
synced 2025-01-01 01:40:21 +05:30
Added serverError exception
This commit is contained in:
parent
758471ec16
commit
9958e1bf80
@ -163,6 +163,18 @@ class OAuthServerException extends \Exception
|
||||
return new static('The user credentials were incorrect.', 'invalid_credentials', 401);
|
||||
}
|
||||
|
||||
/**
|
||||
* Server error
|
||||
*
|
||||
* @param $hint
|
||||
*
|
||||
* @return static
|
||||
*/
|
||||
public static function serverError($hint)
|
||||
{
|
||||
return new static('\'The authorization server encountered an unexpected condition which prevented it from fulfilling the request.', 'server_errror', 500, $hint);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user