From 150ee972ed69fed6bdafe3ff23854ca97234a2c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Kowalik?= Date: Sun, 10 Mar 2019 14:04:16 +0100 Subject: [PATCH] #654 fix code analysis issues --- src/Mutator/Extensions/MBString.php | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/Mutator/Extensions/MBString.php b/src/Mutator/Extensions/MBString.php index 3dd3e686a..adf45ea9c 100644 --- a/src/Mutator/Extensions/MBString.php +++ b/src/Mutator/Extensions/MBString.php @@ -128,13 +128,7 @@ private function mapName(string $functionName): callable private function mapNameSkipArg(string $functionName, int $skipArgs): callable { return function (Node\Expr\FuncCall $node) use ($functionName, $skipArgs): Generator { - $args = $node->args; - - if ($skipArgs !== null) { - $args = \array_slice($args, 0, $skipArgs); - } - - yield $this->createNode($node, $functionName, $args); + yield $this->createNode($node, $functionName, \array_slice($node->args, 0, $skipArgs)); }; } @@ -165,8 +159,6 @@ private function getConvertCaseModeValue(Node\Expr\FuncCall $node): ?int $mode = $node->args[1]->value; - $modeValue = null; - if ($mode instanceof Node\Expr\ConstFetch) { $modeName = $mode->name->toString();