Add new persistprop common function

This commit is contained in:
osm0sis
2025-06-07 08:57:58 -03:00
parent b4eae8a6b6
commit 77f91e3a85
2 changed files with 16 additions and 8 deletions
+8 -8
View File
@@ -62,17 +62,17 @@ done
# Work around custom ROM PropImitationHooks conflict when their persist props don't exist
if [ -n "$(resetprop ro.aospa.version)" -o -n "$(resetprop net.pixelos.version)" -o -n "$(resetprop ro.afterlife.version)" ]; then
for PROP in persist.sys.pihooks.first_api_level persist.sys.pihooks.security_patch; do
resetprop | grep -q "\[$PROP\]" || resetprop -n -p "$PROP" ""
resetprop | grep -q "\[$PROP\]" || persistprop "$PROP" ""
done
fi
# Work around supported custom ROM PropImitationHooks/PixelPropsUtils (and hybrids) conflict when spoofProvider is disabled
if resetprop | grep -qE "persist.sys.pihooks|persist.sys.entryhooks|persist.sys.pixelprops"; then
resetprop -n -p persist.sys.pihooks.disable.gms_props true
resetprop -n -p persist.sys.pihooks.disable.gms_key_attestation_block true
resetprop -n -p persist.sys.entryhooks_enabled false
resetprop -n -p persist.sys.pixelprops.gms false
resetprop -n -p persist.sys.pixelprops.gapps false
resetprop -n -p persist.sys.pixelprops.google false
resetprop -n -p persist.sys.pixelprops.pi false
persistprop persist.sys.pihooks.disable.gms_props true
persistprop persist.sys.pihooks.disable.gms_key_attestation_block true
persistprop persist.sys.entryhooks_enabled false
persistprop persist.sys.pixelprops.gms false
persistprop persist.sys.pixelprops.gapps false
persistprop persist.sys.pixelprops.google false
persistprop persist.sys.pixelprops.pi false
fi