From a11bfa2c65a25e2839497044c69f16ee328f290e Mon Sep 17 00:00:00 2001 From: Martinski4GitHub <119833648+Martinski4GitHub@users.noreply.github.com> Date: Sun, 16 Nov 2025 21:00:57 -0800 Subject: [PATCH] Code Improvements Modified code to make sure we get correct parameters when changing settings from the WebUI. --- MerlinAU.sh | 14 +++++++------- README.md | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/MerlinAU.sh b/MerlinAU.sh index 7e5edf67..c21b41f6 100644 --- a/MerlinAU.sh +++ b/MerlinAU.sh @@ -4,13 +4,13 @@ # # Original Creation Date: 2023-Oct-01 by @ExtremeFiretop. # Official Co-Author: @Martinski W. - Date: 2023-Nov-01 -# Last Modified: 2025-Nov-10 +# Last Modified: 2025-Nov-16 ################################################################### set -u ## Set version for each Production Release ## readonly SCRIPT_VERSION=1.5.7 -readonly SCRIPT_VERSTAG="25111020" +readonly SCRIPT_VERSTAG="25111620" readonly SCRIPT_NAME="MerlinAU" ## Set to "master" for Production Releases ## SCRIPT_BRANCH="dev" @@ -2544,9 +2544,9 @@ _WebUI_SetEmailConfigFileFromAMTM_() _WriteVarDefToHelperJSFile_ "isEMailConfigEnabledInAMTM" "$isEMailConfigEnabledInAMTM" true } -##------------------------------------------## -## Modified by ExtremeFiretop [2025-May-21] ## -##------------------------------------------## +##----------------------------------------## +## Modified by Martinski W. [2025-Nov-16] ## +##----------------------------------------## _ActionsAfterNewConfigSettings_() { if [ ! -s "${CONFIG_FILE}.bak" ] || \ @@ -2555,7 +2555,7 @@ _ActionsAfterNewConfigSettings_() _ConfigOptionChanged_() { - if diff "$CONFIG_FILE" "${CONFIG_FILE}.bak" | grep -q "$1" + if diff -U0 "$CONFIG_FILE" "${CONFIG_FILE}.bak" | grep -q "$1" then return 0 else return 1 fi @@ -11333,7 +11333,7 @@ _Gnuton_Check_Webs_Update_Script_() # (Re)bind/mount only if remote is newer version OR files differ # if [ "$remoteVersTag" -gt "$localVersTag" ] || \ - ! diff "$FW_UpdateCheckScript" "$dwnldGnutonWebsUpdateFilePath" >/dev/null 2>&1 + ! diff -q "$FW_UpdateCheckScript" "$dwnldGnutonWebsUpdateFilePath" >/dev/null 2>&1 then umount "$FW_UpdateCheckScript" 2>/dev/null mv -f "$dwnldGnutonWebsUpdateFilePath" "$fixedGnutonWebsUpdateFilePath" diff --git a/README.md b/README.md index b0ec690b..1e17d61a 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # MerlinAU - AsusWRT-Merlin Firmware Auto Updater ## v1.5.7 -## 2025-Nov-10 +## 2025-Nov-16 ## WebUI: ![image](https://github.com/user-attachments/assets/9c1dff99-9c13-491b-a7fa-aff924d5f02e)