Exceptions change in Check\Colors, add in Cmbined\ArrayHandler

Chech\Colors now throws correct exceptions for wrong values
Combined\ArrayHandler will throw errors and not return false
This commit is contained in:
Clemens Schwaighofer
2023-08-31 12:07:28 +09:00
parent cd81d15d9a
commit 2fe37bf92a
6 changed files with 42 additions and 39 deletions

View File

@@ -99,7 +99,7 @@ echo "<hr>";
try {
$check = Colors::validateColor('#ab12cd', 99);
print "No Exception";
} catch (\Exception $e) {
} catch (\UnexpectedValueException $e) {
print "ERROR: " . $e->getCode() . ": " . $e->getMessage() . "<br>";
}