From 4e62e1f6efd27289f3bd5f56aed27cdd32762f51 Mon Sep 17 00:00:00 2001 From: El RIDO Date: Mon, 8 Jan 2024 08:09:29 +0100 Subject: [PATCH] address jsverify rngState 87ab3f64de258190c7, fixes #1139 --- js/test/PasteStatus.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/js/test/PasteStatus.js b/js/test/PasteStatus.js index 2e8e6dc7..a233bb48 100644 --- a/js/test/PasteStatus.js +++ b/js/test/PasteStatus.js @@ -27,13 +27,13 @@ describe('PasteStatus', function () { common.jscUrl(), common.jscUrl(false), function (url1, url2) { - const expected1 = common.urlToString(url1), - expected2 = common.urlToString(url2), + const expected1 = common.urlToString(url1).replace(/&(gt|lt)$/, '&$1a'), + expected2 = common.urlToString(url2).replace(/&(gt|lt)$/, '&$1a'), clean = jsdom(); $('body').html('
'); $.PrivateBin.PasteStatus.init(); $.PrivateBin.PasteStatus.createPasteNotification(expected1, expected2); - var result1 = $('#pasteurl')[0].href, + const result1 = $('#pasteurl')[0].href, result2 = $('#deletelink a')[0].href; clean(); return result1 === expected1 && result2 === expected2; @@ -50,7 +50,7 @@ describe('PasteStatus', function () { 'nestring', common.jscUrl(), function (schema, domain, url) { - domain = domain.replace(/\P{Letter}|[\u00AA-\u00BA]/gu,'').toLowerCase(); + domain = domain.replace(/\P{Letter}|[\u00AA-\u00BA]/gu, '').toLowerCase(); if (domain.length === 0) { domain = 'a'; }