Skip to content

Commit

Permalink
fixed PHP Deprecated: Use of "self" in callables is deprecated
Browse files Browse the repository at this point in the history
  • Loading branch information
TomasLudvik authored Mar 25, 2024
1 parent d9f0f58 commit b001a84
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Model/YamlAlphabetical/YamlSortService.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,8 @@ private static function sortArrayKeyWithUnderscoresAsFirst(array $yamlArrayData,
$arrayWithUnderscoreKeys = array_filter($yamlArrayData, [YamlService::class, 'hasArrayKeyUnderscoreAsFirstCharacter'], ARRAY_FILTER_USE_KEY);
$arrayWithOtherKeys = array_filter($yamlArrayData, [YamlService::class, 'hasNotArrayKeyUnderscoreAsFirstCharacter'], ARRAY_FILTER_USE_KEY);

uksort($arrayWithUnderscoreKeys, ['self', 'sortArrayAlphabetical']);
uksort($arrayWithOtherKeys, ['self', 'sortArrayAlphabetical']);
uksort($arrayWithUnderscoreKeys, [__CLASS__, 'sortArrayAlphabetical']);
uksort($arrayWithOtherKeys, [__CLASS__, 'sortArrayAlphabetical']);

$arrayData = array_merge($arrayWithUnderscoreKeys, $arrayWithOtherKeys);

Expand Down

0 comments on commit b001a84

Please sign in to comment.