Fix phpstan issue after updating
This commit is contained in:
parent
b3e428b004
commit
df28a81dae
1 changed files with 4 additions and 0 deletions
|
@ -60,6 +60,10 @@ class NaturalSortingProcessor implements DataProcessorInterface
|
||||||
}
|
}
|
||||||
|
|
||||||
$valuesToSort = ArrayUtility::getValueByPath($processedData, $variablePath);
|
$valuesToSort = ArrayUtility::getValueByPath($processedData, $variablePath);
|
||||||
|
if (is_array($valuesToSort) === false) {
|
||||||
|
throw new \Exception('Variable at "' . $variablePath . '" was not of type array.', 1667911071);
|
||||||
|
}
|
||||||
|
|
||||||
usort($valuesToSort, function (array $variable1, array $variable2) use ($variableSubPath) {
|
usort($valuesToSort, function (array $variable1, array $variable2) use ($variableSubPath) {
|
||||||
$value1 = ArrayUtility::getValueByPath($variable1, $variableSubPath);
|
$value1 = ArrayUtility::getValueByPath($variable1, $variableSubPath);
|
||||||
$value2 = ArrayUtility::getValueByPath($variable2, $variableSubPath);
|
$value2 = ArrayUtility::getValueByPath($variable2, $variableSubPath);
|
||||||
|
|
Loading…
Reference in a new issue