Skip to content

Commit

Permalink
[!]: re-write -> "object oriented" -> try to fix for PHP < 7
Browse files Browse the repository at this point in the history
  • Loading branch information
voku committed Apr 5, 2017
1 parent 123a0fe commit af5d38c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/voku/helper/Phonetic.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ public function phonetic_matches($needle, array $haystack)
}

if (count($result) > 0) {
uksort(
uasort(
$result, function ($a, $b) {
if ($a == $b) {
return 0;
Expand Down
6 changes: 3 additions & 3 deletions tests/PhoneticAlgorithmsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,13 +57,13 @@ public function testPhoneticMatchesSentence()
'Wasche' => 'Wäsche',
'troknen' => 'trocknen',
),
621 => array(
342 => array(
'Wasche' => 'Wäsche',
),
313 => array(
621 => array(
'Wasche' => 'Wäsche',
),
342 => array(
313 => array(
'Wasche' => 'Wäsche',
),
),
Expand Down

0 comments on commit af5d38c

Please sign in to comment.