Skip to content

Commit dd3fc8b

Browse files
committed
rgbahex supports coercing colors leafo#153
1 parent d5aa97c commit dd3fc8b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lessc.inc.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1505,7 +1505,8 @@ function lib_isem($value) {
15051505
}
15061506

15071507
function lib_rgbahex($color) {
1508-
if ($color[0] != 'color')
1508+
$color = $this->coerceColor($color);
1509+
if (is_null($color))
15091510
$this->throwError("color expected for rgbahex");
15101511

15111512
return sprintf("#%02x%02x%02x%02x",

0 commit comments

Comments
 (0)