diff --git a/app/src/main/java/com/sevtinge/hyperceiler/module/hook/getapps/DisableStartPushDialog.kt b/app/src/main/java/com/sevtinge/hyperceiler/module/hook/getapps/DisableStartPushDialog.kt index 1c790c1ec..e4899294c 100644 --- a/app/src/main/java/com/sevtinge/hyperceiler/module/hook/getapps/DisableStartPushDialog.kt +++ b/app/src/main/java/com/sevtinge/hyperceiler/module/hook/getapps/DisableStartPushDialog.kt @@ -9,16 +9,15 @@ import com.sevtinge.hyperceiler.module.base.* object DisableStartPushDialog : BaseHook() { override fun init() { // 禁用开启推送弹窗 - loadClass("com.xiaomi.market.util.NotificationUtils").methodFinder() - .filterByName("isNotificationEnabled") - .filterByParamTypes(String::class.java) + loadClass("com.xiaomi.market.ui.UpdateListFragment").methodFinder() + .filterByName("tryShowDialog") .first().createHook { - returnConstant(true) + interrupt() } - loadClass("com.xiaomi.market.util.SettingsUtils").methodFinder() - .filterByName("shouldNotifyUpdate") + loadClass("com.xiaomi.market.ui.update.UpdatePushDialogManager").methodFinder() + .filterByName("tryShowDialog") .first().createHook { - returnConstant(true) + interrupt() } } } \ No newline at end of file