Skip to content

Commit ab66cff

Browse files
authored
[CLEANUP] Rector: Add method return type based on strict ternary values (#588)
This applies the rule ReturnTypeFromStrictTernaryRector. For Details see: https://github.com/rectorphp/rector/blob/main/docs/rector_rules_overview.md#returntypefromstrictternaryrector Signed-off-by: Daniel Ziegenberg <daniel@ziegenberg.at>
1 parent 88f67b0 commit ab66cff

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

src/CSSList/CSSList.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -241,10 +241,8 @@ private static function parseAtRule(ParserState $oParserState)
241241
*
242242
* @param string $sIdentifier
243243
* @param string $sMatch
244-
*
245-
* @return bool
246244
*/
247-
private static function identifierIs($sIdentifier, $sMatch)
245+
private static function identifierIs($sIdentifier, $sMatch): bool
248246
{
249247
return (strcasecmp($sIdentifier, $sMatch) === 0)
250248
?: preg_match("/^(-\\w+-)?$sMatch$/i", $sIdentifier) === 1;

src/Parsing/ParserState.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -258,10 +258,8 @@ public function consumeWhiteSpace(): array
258258
/**
259259
* @param string $sString
260260
* @param bool $bCaseInsensitive
261-
*
262-
* @return bool
263261
*/
264-
public function comes($sString, $bCaseInsensitive = false)
262+
public function comes($sString, $bCaseInsensitive = false): bool
265263
{
266264
$sPeek = $this->peek(strlen($sString));
267265
return ($sPeek == '')

0 commit comments

Comments
 (0)