Lucas_Werkmeister_WMDE added a comment.

Hm, I don’t think the in_array is the issue – that only checks the $direction, after all, not anything from the $matches, so that should always have the right case. I think the issue is a few lines further up:

if ( $matches[1] === $direction || $matches[3] === $direction ) {

This will be false for all four $directions if the match differs in case, so the method will fall back to the final return $coordinateSegment; outside the loop, without ever adding a minus sign.


TASK DETAIL
https://phabricator.wikimedia.org/T173026

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Lucas_Werkmeister_WMDE
Cc: Lucas_Werkmeister_WMDE, Izno, Aklapper, Nikki, PokestarFan, Lahi, Gq86, GoranSMilovanovic, QZanden, LawExplorer, Wikidata-bugs, aude, Mbch331
_______________________________________________
Wikidata-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to