mirror of
https://github.com/topjohnwu/Magisk.git
synced 2026-01-18 07:37:01 -08:00
Guard env state behind cached objects
This commit is contained in:
@@ -29,7 +29,7 @@ class MagiskRepository(
|
||||
else -> throw IllegalArgumentException()
|
||||
}.flatMap {
|
||||
// If remote version is lower than current installed, try switching to beta
|
||||
if (it.magisk.versionCode < Info.magiskVersionCode
|
||||
if (it.magisk.versionCode < Info.env.magiskVersionCode
|
||||
&& Config.updateChannel == Config.Value.DEFAULT_CHANNEL) {
|
||||
Config.updateChannel = Config.Value.BETA_CHANNEL
|
||||
apiRaw.fetchBetaUpdate()
|
||||
@@ -74,4 +74,4 @@ class MagiskRepository(
|
||||
) }
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user