1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-10-04 05:08:06 +02:00

formatting updates

This commit is contained in:
Kyle Spearrin 2019-02-08 08:03:12 -05:00
parent 4aaf452883
commit 98addd8ab5
2 changed files with 3 additions and 4 deletions

View File

@ -78,7 +78,7 @@ export class LoginUriView implements View {
if (this._canLaunch != null) {
return this._canLaunch;
}
if (this.uri != null && this.match != UriMatchType.RegularExpression) {
if (this.uri != null && this.match !== UriMatchType.RegularExpression) {
const uri = this.launchUri;
for (let i = 0; i < CanLaunchWhitelist.length; i++) {
if (uri.indexOf(CanLaunchWhitelist[i]) === 0) {

View File

@ -31,17 +31,16 @@ export class LoginView implements View {
}
get canLaunch(): boolean {
return this.hasUris && this.uris.some(uri => uri.canLaunch);
return this.hasUris && this.uris.some((u) => u.canLaunch);
}
get launchUri(): string {
if (this.hasUris) {
const uri = this.uris.find(uri => uri.canLaunch)
const uri = this.uris.find((u) => u.canLaunch);
if (uri != null) {
return uri.launchUri;
}
}
return null;
}