Untitled
unknown
plain_text
3 years ago
547 B
21
Indexable
private boolean canDoCheckVersionInvalid() {
SharedPreferences preferences =
Preferences.get(mPresenter.getContext(), PREFS_CHECK_VERSION);
int maxCount = 1; //3
int count = preferences.getInt(PREFS_KEY_COUNT, maxCount);
boolean can = false;
if (count == maxCount) {
can = true;
count = 0;
} else {
count++;
}
preferences.edit()
.putInt(PREFS_KEY_COUNT, count)
.apply();
return can;
}Editor is loading...