From 32d51e2680f4512bd37c26e3be2f8ac3d15e4f67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Tue, 14 Jul 2020 10:01:54 +0200 Subject: [PATCH] MOBILE-3452 scripts: Fix minor warnings on scripts --- scripts/functions.sh | 1 - scripts/lang_functions.php | 4 +--- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/scripts/functions.sh b/scripts/functions.sh index c875be20f..f90399189 100644 --- a/scripts/functions.sh +++ b/scripts/functions.sh @@ -1,7 +1,6 @@ #!/bin/bash LANGPACKSFOLDER='../../moodle-langpacks' -stepnumber=$1 function check_success_exit { if [ $? -ne 0 ]; then diff --git a/scripts/lang_functions.php b/scripts/lang_functions.php index 7025faa8e..ea94ec3d1 100644 --- a/scripts/lang_functions.php +++ b/scripts/lang_functions.php @@ -186,7 +186,7 @@ function build_lang($lang, $keys) { $local = 0; $langparts = explode('-', $lang, 2); - $parentname = $langparts[0] ?? ""; + $parentname = $langparts[0] ? $langparts[0] : ""; $parent = ""; echo "Processing $lang"; @@ -307,8 +307,6 @@ function detect_lang($lang, $keys) { $langname = $string['thislanguage']; $title .= " ".$langname." -D"; - - // Add the translation to the array. foreach ($keys as $key => $value) { $string = get_translation_strings($langfoldername, $value->file);