mirror of
https://github.com/M66B/NetGuard.git
synced 2025-01-01 12:54:07 +00:00
Revert "Keep using old method to acquire DNS servers for now"
This reverts commit fd3b56eb8c
.
This commit is contained in:
parent
4fc1ac6e2c
commit
0882f40c73
1 changed files with 1 additions and 1 deletions
|
@ -271,7 +271,7 @@ public class Util {
|
|||
public static List<String> getDefaultDNS(Context context) {
|
||||
String dns1 = null;
|
||||
String dns2 = null;
|
||||
if (android.os.Build.VERSION.SDK_INT > android.os.Build.VERSION_CODES.N) {
|
||||
if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.M) {
|
||||
ConnectivityManager cm = (ConnectivityManager) context.getSystemService(Context.CONNECTIVITY_SERVICE);
|
||||
Network an = cm.getActiveNetwork();
|
||||
if (an != null) {
|
||||
|
|
Loading…
Reference in a new issue