mirror of
https://github.com/elyby/oauth2-server.git
synced 2025-05-31 14:12:07 +05:30
Added serverError exception
This commit is contained in:
@@ -163,6 +163,18 @@ class OAuthServerException extends \Exception
|
|||||||
return new static('The user credentials were incorrect.', 'invalid_credentials', 401);
|
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
|
* @return string
|
||||||
*/
|
*/
|
||||||
|
Reference in New Issue
Block a user