mirror of https://github.com/M66B/FairEmail.git
Refactoring
This commit is contained in:
parent
b35a63dff9
commit
6f268c1b56
|
@ -147,8 +147,7 @@ abstract class ActivityBase extends AppCompatActivity implements SharedPreferenc
|
|||
|
||||
if (pm != null && !pm.isInteractive()) {
|
||||
Log.i("Stop with screen off");
|
||||
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(ActivityBase.this);
|
||||
prefs.edit().remove("last_authentication").apply();
|
||||
Helper.clearAuthentication(this);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -751,6 +751,11 @@ public class Helper {
|
|||
prompt.authenticate(info.build());
|
||||
}
|
||||
|
||||
static void clearAuthentication(Context context) {
|
||||
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context);
|
||||
prefs.edit().remove("last_authentication").apply();
|
||||
}
|
||||
|
||||
// Miscellaneous
|
||||
|
||||
static String sanitizeKeyword(String keyword) {
|
||||
|
|
Loading…
Reference in New Issue