Skip to content

Commit 95ce6d1

Browse files
committed
Further changes suggested in review.
1 parent 3f54b77 commit 95ce6d1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Value/Color.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ public static function parse(ParserState $oParserState, bool $bIgnoreCase = fals
8383
$colorModeForParsing = 'hsla';
8484
$mayHaveOptionalAlpha = true;
8585
break;
86-
// These two cases are handled identically.
8786
case 'rgba':
87+
// This is handled identically to the following case.
8888
case 'hsla':
8989
$colorModeForParsing = $sColorMode;
9090
$mayHaveOptionalAlpha = true;
@@ -112,7 +112,7 @@ public static function parse(ParserState $oParserState, bool $bIgnoreCase = fals
112112
// And as of CSS Color Module Level 4, the alpha argument is optional.
113113
$canCloseNow =
114114
$bContainsVar ||
115-
$mayHaveOptionalAlpha && $i >= $iLength - 2;
115+
($mayHaveOptionalAlpha && $i >= $iLength - 2);
116116
if ($canCloseNow && $oParserState->comes(')')) {
117117
break;
118118
}

0 commit comments

Comments
 (0)