Add custom exception MDInvalidColorCode
This commit is contained in:
parent
4992011939
commit
231a9d48a4
19
exceptions/generic/MDInvalidColorCode.php
Normal file
19
exceptions/generic/MDInvalidColorCode.php
Normal file
@ -0,0 +1,19 @@
|
||||
<?PHP
|
||||
declare(strict_types = 1);
|
||||
|
||||
/**
|
||||
* Exception thrown in case a color code is not valid.
|
||||
*/
|
||||
final class MDInvalidColorCode extends MDgenericInvalidInputsException {
|
||||
/**
|
||||
* Error message.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function errorMessage() {
|
||||
//error message
|
||||
$errorMsg = 'Input color code is invalid';
|
||||
return $errorMsg;
|
||||
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user