diff --git a/src/Exception/InvalidJsonHttpException.php b/src/Exception/InvalidJsonHttpException.php index a58e199..3ad510c 100644 --- a/src/Exception/InvalidJsonHttpException.php +++ b/src/Exception/InvalidJsonHttpException.php @@ -19,6 +19,7 @@ final class InvalidJsonHttpException extends HttpException implements JsonHttpEx { public function __construct() { + trigger_deprecation('tilleuls/forgot-password-bundle', '1.5', 'Status code will change to "%s" in 2.0.', 422); parent::__construct(400, 'Invalid JSON data.'); } } diff --git a/src/Exception/NoParameterException.php b/src/Exception/NoParameterException.php index 2b04f83..8965d67 100644 --- a/src/Exception/NoParameterException.php +++ b/src/Exception/NoParameterException.php @@ -19,6 +19,7 @@ final class NoParameterException extends HttpException implements JsonHttpExcept { public function __construct() { + trigger_deprecation('tilleuls/forgot-password-bundle', '1.5', 'Status code will change to "%s" in 2.0.', 422); parent::__construct(400, 'No parameter sent.'); } } diff --git a/src/Exception/UnauthorizedFieldException.php b/src/Exception/UnauthorizedFieldException.php index b582ecf..48bef86 100644 --- a/src/Exception/UnauthorizedFieldException.php +++ b/src/Exception/UnauthorizedFieldException.php @@ -19,6 +19,7 @@ final class UnauthorizedFieldException extends HttpException implements JsonHttp { public function __construct($propertyName) { + trigger_deprecation('tilleuls/forgot-password-bundle', '1.5', 'Status code will change to "%s" in 2.0.', 422); parent::__construct(400, \sprintf('The parameter "%s" is not authorized in your configuration.', $propertyName)); } } diff --git a/src/Exception/UndefinedProviderException.php b/src/Exception/UndefinedProviderException.php index 9619bc3..4898125 100644 --- a/src/Exception/UndefinedProviderException.php +++ b/src/Exception/UndefinedProviderException.php @@ -19,6 +19,7 @@ final class UndefinedProviderException extends HttpException implements JsonHttp { public function __construct(string $message = 'This provider is not defined.') { + trigger_deprecation('tilleuls/forgot-password-bundle', '1.5', 'Status code will change to "%s" in 2.0.', 422); parent::__construct(400, $message); } }