From 8495a03947009cea721a54fbf7afcd97eeea40c4 Mon Sep 17 00:00:00 2001 From: osm0sis Date: Tue, 13 Jan 2026 21:47:42 -0400 Subject: [PATCH] Fix A-only addon.d retaining PREINITDEVICE on 30300+ - broken after https://github.com/topjohnwu/Magisk/commit/742913ebcb10cf819a54699497359535047874f7 so use get_flags to be more futureproof --- scripts/addon.d.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/addon.d.sh b/scripts/addon.d.sh index d284a538a..de81bd188 100644 --- a/scripts/addon.d.sh +++ b/scripts/addon.d.sh @@ -137,7 +137,9 @@ case "$1" in # Back up PREINITDEVICE from existing partition before OTA on A-only devices if ! $backuptool_ab; then initialize - RECOVERYMODE=false + # Suppress ui_print for this stage + ui_print() { return; } + get_flags find_boot_image $MAGISKBIN/magiskboot unpack "$BOOTIMAGE" $MAGISKBIN/magiskboot cpio ramdisk.cpio "extract .backup/.magisk config.orig"