summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/webcolor.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/webcolor.php b/lib/webcolor.php
index 65713d26e..aaf31d990 100644
--- a/lib/webcolor.php
+++ b/lib/webcolor.php
@@ -120,7 +120,8 @@ class WebColor {
$hexcolor[1].$hexcolor[1],
$hexcolor[2].$hexcolor[2]);
} else {
- return false;
+ $errmsg = _('%s is not a valid color! Use 3 or 6 hex chars.');
+ throw new WebColorException(sprintf($errmsg, $hexcolor));
}
$this->red = hexdec($r);