1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-09-13 01:58:44 +02:00

regular fetch for password check

This commit is contained in:
Kyle Spearrin 2018-07-18 15:09:13 -04:00
parent 257b1d7d7a
commit f4ed6a5566

View File

@ -18,7 +18,7 @@ export class AuditService implements AuditServiceAbstraction {
const hashStart = hash.substr(0, 5);
const hashEnding = hash.substr(5);
const response = await this.apiService.fetch(new Request(PwnedPasswordsApi + hashStart));
const response = await fetch(new Request(PwnedPasswordsApi + hashStart));
const leakedHashes = await response.text();
const match = leakedHashes.split(/\r?\n/).find((v) => {
return v.split(':')[0] === hashEnding;