]> git.openstreetmap.org Git - nominatim.git/commitdiff
Merge remote-tracking branch 'upstream/master'
authorSarah Hoffmann <lonvia@denofr.de>
Sun, 30 Jun 2019 08:48:58 +0000 (10:48 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Sun, 30 Jun 2019 08:48:58 +0000 (10:48 +0200)
1  2 
lib/Geocode.php

diff --combined lib/Geocode.php
index e2d676862a5f6a3c74cd002d4818e211c0ee9567,7a9f5ad4f2799531c726712dd302612c99dc455f..12410acc81a03373bdbd9e44d1dbee84daf13307
@@@ -18,7 -18,7 +18,7 @@@ class Geocod
      protected $aLangPrefOrder = array();
  
      protected $aExcludePlaceIDs = array();
 -    protected $bReverseInPlan = false;
 +    protected $bReverseInPlan = true;
  
      protected $iLimit = 20;
      protected $iFinalLimit = 10;
              $aNewPhraseSearches = array();
              $sPhraseType = $bIsStructured ? $oPhrase->getPhraseType() : '';
  
-             foreach ($oPhrase->getWordSets() as $iWordSet => $aWordset) {
-                 // Too many permutations - too expensive
-                 if ($iWordSet > 120) break;
+             foreach ($oPhrase->getWordSets() as $aWordset) {
                  $aWordsetSearches = $aSearches;
  
                  // Add all words from this wordset
                  }
              }
  
-             Debug::printDebugTable('Phrases', $aPhrases);
              Debug::printVar('Tokens', $aTokens);
  
              $oValidTokens = new TokenList();
  
                  Debug::printGroupTable('Valid Tokens', $oValidTokens->debugInfo());
  
+                 foreach ($aPhrases as $oPhrase) {
+                     $oPhrase->computeWordSets($oValidTokens);
+                 }
+                 Debug::printDebugTable('Phrases', $aPhrases);
                  Debug::newSection('Search candidates');
  
                  $aGroupedSearches = $this->getGroupedSearches($aSearches, $aPhrases, $oValidTokens, $bStructuredPhrases);