mirror of
https://github.com/M66B/FairEmail.git
synced 2026-03-27 19:35:10 +01:00
Added fail-safe
This commit is contained in:
@@ -512,8 +512,13 @@ public class ConnectionHelper {
|
||||
}
|
||||
|
||||
static boolean airplaneMode(Context context) {
|
||||
return Settings.Global.getInt(context.getContentResolver(),
|
||||
Settings.Global.AIRPLANE_MODE_ON, 0) != 0;
|
||||
try {
|
||||
return (Settings.Global.getInt(context.getContentResolver(),
|
||||
Settings.Global.AIRPLANE_MODE_ON, 0) != 0);
|
||||
} catch (Throwable ex) {
|
||||
Log.e(ex);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
static InetAddress from6to4(InetAddress addr) {
|
||||
|
||||
Reference in New Issue
Block a user