X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/f05ea577f42c5ad4a62ff25ec62fbb60c550ee26..2a784fa3d4533d11e3227f868085dcee5a9870c6:/utils/specialphrases.php?ds=sidebyside diff --git a/utils/specialphrases.php b/utils/specialphrases.php index bdbd6735..652230fc 100755 --- a/utils/specialphrases.php +++ b/utils/specialphrases.php @@ -6,14 +6,15 @@ require_once(CONST_BasePath.'/lib/init-cmd.php'); ini_set('memory_limit', '800M'); ini_set('display_errors', 'stderr'); -$aCMDOptions = array( - "Import and export special phrases", - array('help', 'h', 0, 1, 0, 0, false, 'Show Help'), - array('quiet', 'q', 0, 1, 0, 0, 'bool', 'Quiet output'), - array('verbose', 'v', 0, 1, 0, 0, 'bool', 'Verbose output'), - array('countries', '', 0, 1, 0, 0, 'bool', 'Create import script for country codes and names'), - array('wiki-import', '', 0, 1, 0, 0, 'bool', 'Create import script for search phrases '), -); +$aCMDOptions += array( + "Import and export special phrases", + array('help', 'h', 0, 1, 0, 0, false, 'Show Help'), + array('quiet', 'q', 0, 1, 0, 0, 'bool', 'Quiet output'), + array('verbose', 'v', 0, 1, 0, 0, 'bool', 'Verbose output'), + array('countries', '', 0, 1, 0, 0, 'bool', 'Create import script for country codes and names'), + array('wiki-import', '', 0, 1, 0, 0, 'bool', 'Create import script for search phrases '), + ); getCmdOpt($_SERVER['argv'], $aCMDOptions, $aCMDResult, true, true); include(CONST_InstallPath.'/settings/phrase_settings.php'); @@ -45,8 +46,9 @@ if ($aCMDResult['wiki-import']) { # quotes into the wiki $sType = preg_replace('/"/', '', $sType); # sanity check, in case somebody added garbage in the wiki - if (preg_match('/^\\w+$/', $sClass) < 1 || - preg_match('/^\\w+$/', $sType) < 1) { + if (preg_match('/^\\w+$/', $sClass) < 1 + || preg_match('/^\\w+$/', $sType) < 1 + ) { trigger_error("Bad class/type for language $sLanguage: $sClass=$sType"); exit; }