mirror of
https://github.com/bitwarden/jslib
synced 2025-12-11 22:03:31 +00:00
Remove empty catch blocks, and update tslint rule (#513)
This commit is contained in:
@@ -238,7 +238,9 @@ export class Utils {
|
||||
|
||||
const urlDomain = tldjs != null && tldjs.getDomain != null ? tldjs.getDomain(url.hostname) : null;
|
||||
return urlDomain != null ? urlDomain : url.hostname;
|
||||
} catch (e) { }
|
||||
} catch (e) {
|
||||
// Invalid domain, try another approach below.
|
||||
}
|
||||
}
|
||||
|
||||
try {
|
||||
@@ -367,7 +369,9 @@ export class Utils {
|
||||
anchor.href = uriString;
|
||||
return anchor as any;
|
||||
}
|
||||
} catch (e) { }
|
||||
} catch (e) {
|
||||
// Ignore error
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user