fix: Wrap DNS check in catch to avoid runtime crash
parent
645d58d513
commit
8f7730575e
|
@ -218,6 +218,7 @@ class ServerInstallationRepository {
|
||||||
final Map<String, bool> skippedMatches,
|
final Map<String, bool> skippedMatches,
|
||||||
) async {
|
) async {
|
||||||
final Map<String, bool> matches = <String, bool>{};
|
final Map<String, bool> matches = <String, bool>{};
|
||||||
|
try {
|
||||||
await InternetAddress.lookup(domainName!).then(
|
await InternetAddress.lookup(domainName!).then(
|
||||||
(final records) {
|
(final records) {
|
||||||
for (final record in records) {
|
for (final record in records) {
|
||||||
|
@ -231,6 +232,9 @@ class ServerInstallationRepository {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
);
|
);
|
||||||
|
} catch (e) {
|
||||||
|
print(e);
|
||||||
|
}
|
||||||
|
|
||||||
return matches;
|
return matches;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue