mirror of
https://github.com/M66B/NetGuard.git
synced 2025-02-24 07:10:50 +00:00
Merge pull request #202 from marco-scavuzzo/master
Workaround for devices with 3G/LTE returning false when calling hasSy…
This commit is contained in:
commit
312f5b5417
1 changed files with 2 additions and 1 deletions
|
@ -84,7 +84,8 @@ public class Util {
|
|||
|
||||
public static boolean hasTelephony(Context context) {
|
||||
PackageManager pm = context.getPackageManager();
|
||||
return pm.hasSystemFeature(PackageManager.FEATURE_TELEPHONY);
|
||||
return pm.hasSystemFeature(PackageManager.FEATURE_TELEPHONY) ||
|
||||
context.getSystemService(Context.TELEPHONY_SERVICE)!=null;
|
||||
}
|
||||
|
||||
public static boolean hasWifi(Context context) {
|
||||
|
|
Loading…
Reference in a new issue