diff --git a/xcode/aux_scripts/import_strings.php b/xcode/aux_scripts/import_strings.php index 52f79d6..7cfdc7d 100644 --- a/xcode/aux_scripts/import_strings.php +++ b/xcode/aux_scripts/import_strings.php @@ -7,7 +7,7 @@ mkdir($path, 0777, true); } } - + $localization = './'.$PRODUCT_NAME.'/Resources/Localization/'; $baseFile = file_get_contents(array_pop(glob($COMMON_STRINGS_PATH.'/default*.json'))); @@ -19,6 +19,11 @@ $jsonFile = file_get_contents($file); $json = array_merge($baseJson, json_decode($jsonFile, true)); + + if ($json == null) { + echo "Invalid JSON format\n"; + exit(1); + } $ios_strings = ""; foreach ($json as $key=>$value) {