Fix linting in connectors (#1293)

This commit is contained in:
Thomas Rittson 2021-11-11 13:35:35 +10:00 committed by GitHub
parent 57031e7752
commit 40c37143e0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 5 deletions

View File

@ -13,7 +13,7 @@ document.addEventListener('DOMContentLoaded', event => {
const hostParam = getQsParam('host');
const requestParam = getQsParam('request');
var hostUrl = new URL('https://' + hostParam);
const hostUrl = new URL('https://' + hostParam);
if (!hostUrl.hostname.endsWith('.duosecurity.com') && !hostUrl.hostname.endsWith('.duofederal.com')) {
return;
}

View File

@ -25,9 +25,9 @@ function initiateBrowserSso(code: string, state: string) {
window.postMessage({ command: 'authResult', code: code, state: state }, '*');
const handOffMessage = ('; ' + document.cookie).split('; ssoHandOffMessage=').pop().split(';').shift();
document.cookie = 'ssoHandOffMessage=;SameSite=strict;max-age=0';
let content = document.getElementById('content');
const content = document.getElementById('content');
content.innerHTML = '';
let p = document.createElement('p');
const p = document.createElement('p');
p.innerText = handOffMessage;
content.appendChild(p);
}

View File

@ -4,6 +4,8 @@ import { buildDataString, parseWebauthnJson } from './common-webauthn';
// tslint:disable-next-line
require('./webauthn.scss');
const mobileCallbackUri = 'bitwarden://webauthn-callback';
let parsed = false;
let webauthnJson: any;
let headerText: string = null;
@ -12,7 +14,6 @@ let btnReturnText: string = null;
let parentUrl: string = null;
let parentOrigin: string = null;
let mobileResponse = false;
let mobileCallbackUri = 'bitwarden://webauthn-callback';
let stopWebAuthn = false;
let sentSuccess = false;
let obj: any = null;
@ -82,7 +83,7 @@ function parseParametersV2() {
btnText: string;
btnReturnText: string;
callbackUri?: string;
mobile?: boolean
mobile?: boolean
} = null;
try {
dataObj = JSON.parse(b64Decode(getQsParam('data')));