]> git.openstreetmap.org Git - nominatim.git/blobdiff - lib/Geocode.php
actually write back the reversed final phrase when reversing the query
[nominatim.git] / lib / Geocode.php
index 22ad43327adcfd7cf3851257886cd9c1e226d118..e441e8869c479a7cc351e77290018054de310365 100644 (file)
                                                if (sizeof($aPhrases) > 1)
                                                {
                                                        $aFinalPhrase = end($aPhrases);
-                                                       $aFinalPhrase['wordsets'] = getInverseWordSets($aFinalPhrase['words'], 0);
+                                                       $aPhrases[sizeof($aPhrases)-1]['wordsets'] = getInverseWordSets($aFinalPhrase['words'], 0);
                                                }
                                                $aReverseGroupedSearches = $this->getGroupedSearches($aSearches, null, $aPhrases, $aValidTokens, $aWordFrequencyScores, false);