Skip to content

Commit 7d4d061

Browse files
committed
refactor: to fix psalm error
ERROR: TooFewArguments - system/Language/Language.php:255:24 - Too few arguments for array_replace_recursive - expecting array to be passed (see https://psalm.dev/025) $strings = array_replace_recursive(...$strings);
1 parent 133113d commit 7d4d061

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

system/Language/Language.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,9 @@ protected function requireFile(string $path): array
252252
}
253253

254254
if (isset($strings[1])) {
255-
$strings = array_replace_recursive(...$strings);
255+
$string = array_shift($strings);
256+
257+
$strings = array_replace_recursive($string, ...$strings);
256258
} elseif (isset($strings[0])) {
257259
$strings = $strings[0];
258260
}

0 commit comments

Comments
 (0)