From 78f5455b69bb1fa9ce5086920a94cf72a20689e8 Mon Sep 17 00:00:00 2001 From: AuxXxilium Date: Sun, 10 Nov 2024 17:39:26 +0100 Subject: [PATCH] arc: more ... Signed-off-by: AuxXxilium --- files/initrd/opt/arc/arc-functions.sh | 2 -- files/initrd/opt/arc/arc.sh | 4 ++++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/files/initrd/opt/arc/arc-functions.sh b/files/initrd/opt/arc/arc-functions.sh index 693a19d9..77ad8ccc 100755 --- a/files/initrd/opt/arc/arc-functions.sh +++ b/files/initrd/opt/arc/arc-functions.sh @@ -2229,7 +2229,6 @@ function checkHardwareID() { if echo "${USERID}" | grep -vq "Hardware ID"; then writeConfigKey "arc.hwid" "${HWID}" "${USER_CONFIG_FILE}" writeConfigKey "arc.userid" "${USERID}" "${USER_CONFIG_FILE}" - writeConfigKey "arc.patch" "true" "${USER_CONFIG_FILE}" if [ -n "${USERID}" ] && [ -n "${HWID}" ]; then cp -f "${S_FILE}" "${S_FILE}.bak" curl -skL "https://arc.auxxxilium.tech?hwid=${HWID}&userid=${USERID}" > "${S_FILE}" @@ -2237,7 +2236,6 @@ function checkHardwareID() { else dialog --backtitle "$(backtitle)" --title "HardwareID" \ --infobox "Couldn't verify your HardwareID!\nArc Patch not enabled!" 6 40 - writeConfigKey "arc.patch" "false" "${USER_CONFIG_FILE}" cp -f "${S_FILE}.bak" "${S_FILE}" sleep 3 fi diff --git a/files/initrd/opt/arc/arc.sh b/files/initrd/opt/arc/arc.sh index 154a7688..94f9171a 100755 --- a/files/initrd/opt/arc/arc.sh +++ b/files/initrd/opt/arc/arc.sh @@ -409,6 +409,8 @@ function arcPatch() { # Check for Custom Build if [ "${ARCMODE}" == "automated" ]; then [ -z "${ARCCONF}" ] && checkHardwareID || true + sleep 2 + ARCCONF="$(readConfigKey "${MODEL}.serial" "${S_FILE}")" [ -n "${ARCCONF}" ] && SN="$(generateSerial "${MODEL}" "true")" || SN="$(generateSerial "${MODEL}" "false")" [ -n "${ARCCONF}" ] && writeConfigKey "arc.patch" "true" "${USER_CONFIG_FILE}" || writeConfigKey "arc.patch" "false" "${USER_CONFIG_FILE}" elif [ "${ARCMODE}" == "config" ]; then @@ -423,6 +425,8 @@ function arcPatch() { [ -z "${resp}" ] && return 1 if [ ${resp} -eq 1 ]; then [ -z "${ARCCONF}" ] && checkHardwareID || true + sleep 2 + ARCCONF="$(readConfigKey "${MODEL}.serial" "${S_FILE}")" [ -n "${ARCCONF}" ] && SN="$(generateSerial "${MODEL}" "true")" || SN="$(generateSerial "${MODEL}" "false")" [ -n "${ARCCONF}" ] && writeConfigKey "arc.patch" "true" "${USER_CONFIG_FILE}" || writeConfigKey "arc.patch" "false" "${USER_CONFIG_FILE}" elif [ ${resp} -eq 2 ]; then