Disable update check for third part builds

This commit is contained in:
M66B 2020-01-10 14:10:34 +01:00
parent ed535cabd2
commit 72850f2764
2 changed files with 6 additions and 2 deletions

View File

@ -312,9 +312,11 @@ public class ActivitySettings extends AppCompatActivity implements SharedPrefere
pref_rcode.setTitle(getString(R.string.setting_rcode, prefs.getString("rcode", "3")));
if (Util.isPlayStoreInstall(this) || !Util.hasValidFingerprint(this))
cat_options.removePreference(screen.findPreference("update_check"));
if (Util.isPlayStoreInstall(this)) {
Log.i(TAG, "Play store install");
cat_options.removePreference(screen.findPreference("update_check"));
cat_advanced.removePreference(pref_block_domains);
cat_advanced.removePreference(pref_rcode);
cat_advanced.removePreference(pref_forwarding);

View File

@ -650,7 +650,9 @@ public class ServiceSinkhole extends VpnService implements SharedPreferences.OnS
// Check for update
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(ServiceSinkhole.this);
if (!Util.isPlayStoreInstall(ServiceSinkhole.this) && prefs.getBoolean("update_check", true))
if (!Util.isPlayStoreInstall(ServiceSinkhole.this) &&
Util.hasValidFingerprint(ServiceSinkhole.this) &&
prefs.getBoolean("update_check", true))
checkUpdate();
}