Refactoring

pull/206/head
M66B 3 years ago
parent 3db56f49ea
commit e43744eb88

@ -123,11 +123,10 @@ public class Bimi {
if (TextUtils.isEmpty(l))
continue;
try {
Uri ul = Uri.parse(l);
if (!"https".equals(ul.getScheme())) {
Log.e("BIMI insecure img=" + l);
continue;
}
if ("https".equals(ul.getScheme()))
throw new MalformedURLException(l);
URL url = new URL(l);
Log.i("BIMI favicon " + url);
@ -146,6 +145,9 @@ public class Bimi {
} finally {
connection.disconnect();
}
} catch (MalformedURLException ex) {
Log.i(ex);
}
break;
}
@ -159,13 +161,11 @@ public class Bimi {
if (TextUtils.isEmpty(a))
continue;
try {
Uri ua = Uri.parse(a);
if (!"https".equals(ua.getScheme())) {
Log.e("BIMI insecure pem=" + a);
continue;
}
if (!"https".equals(ua.getScheme()))
throw new MalformedURLException(a);
try {
URL url = new URL(a);
Log.i("BIMI PEM " + url);

Loading…
Cancel
Save