Skip to content

Commit 0fd2683

Browse files
committed
Fixup
1 parent 1a1c9aa commit 0fd2683

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

webapp/src/Utils/Utils.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -384,9 +384,7 @@ public static function rgbToHex(array $color): string
384384
$result = "#";
385385
if (count($color) === 3) {
386386
$color[] = 255;
387-
} elseif (count($color) !== 4) {
388-
throw Exception("Invalid RGB number.");
389-
}
387+
}
390388
for ($i=0; $i<count($color); $i++) {
391389
$result .= static::componentToHex($color[$i]);
392390
}
@@ -410,7 +408,6 @@ public static function blendAlphaBackground(array $rgba, string $bg): array
410408
}
411409
return $result;
412410
}
413-
throw Exception("Invalid RGB number.");
414411
}
415412

416413
public static function relativeLuminance(string $hexRGB, string $rgb_background = "#fff"): float

0 commit comments

Comments
 (0)