diff --git a/app/src/main/java/com/github/yueeng/moebooru/Common.kt b/app/src/main/java/com/github/yueeng/moebooru/Common.kt index 5d731b4..607b92e 100644 --- a/app/src/main/java/com/github/yueeng/moebooru/Common.kt +++ b/app/src/main/java/com/github/yueeng/moebooru/Common.kt @@ -1056,8 +1056,9 @@ fun AppCompatActivity.checkAppUpdate(pre: Boolean = false, compare: Boolean = fa .setTitle(name) .setMessage(latest.body) .setPositiveButton(getString(R.string.app_download)) { _, _ -> openWeb(url) } - .setNegativeButton(R.string.app_update_ignore) { _, _ -> MoeSettings.updateVersion.setValueToPreferences(latest.tagName) } .apply { + if (compare) setNegativeButton(R.string.app_update_ignore) { _, _ -> MoeSettings.updateVersion.setValueToPreferences(latest.tagName) } + else setNegativeButton(R.string.app_cancel, null) if (!pre) setNeutralButton(getString(R.string.app_pre_release)) { _, _ -> checkAppUpdate(true) } diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 2b6a7cb..9a12749 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -26,7 +26,7 @@ glide_transformations = "4.3.0" gesture_views = "2.8.3" jsoup = "1.17.2" uCrop = "2020.09.28" -github_api = "1.315" +github_api = "1.319" junit = "4.13.2" androidx_test_ext_junit = "1.1.5" androidx_test_espresso = "3.5.1"