mirror of https://github.com/M66B/FairEmail.git
Added fail safe
This commit is contained in:
parent
6e367fb420
commit
476667ee3a
|
@ -418,8 +418,13 @@ public class Helper {
|
|||
}
|
||||
|
||||
static boolean canPrint(Context context) {
|
||||
PackageManager pm = context.getPackageManager();
|
||||
return pm.hasSystemFeature(PackageManager.FEATURE_PRINTING);
|
||||
try {
|
||||
PackageManager pm = context.getPackageManager();
|
||||
return pm.hasSystemFeature(PackageManager.FEATURE_PRINTING);
|
||||
} catch (Throwable ex) {
|
||||
Log.e(ex);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
static Boolean isIgnoringOptimizations(Context context) {
|
||||
|
|
Loading…
Reference in New Issue