From 8c11a0131d24ec89e3712e17a389e03e7df1dcdf Mon Sep 17 00:00:00 2001 From: sancodes Date: Fri, 20 May 2022 01:37:11 -0700 Subject: [PATCH] modify inline code to multiple line --- src/components/apphost.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/components/apphost.js b/src/components/apphost.js index 27cce3dda0..337e346df2 100644 --- a/src/components/apphost.js +++ b/src/components/apphost.js @@ -75,7 +75,9 @@ function replaceAll(originalString, strReplace, strWith) { function generateDeviceId() { const keys = []; - if ((keys.push(navigator.userAgent), keys.push(new Date().getTime()), window.btoa)) { + keys.push(navigator.userAgent); + keys.push(new Date().getTime()); + if (window.btoa) { const result = replaceAll(btoa(keys.join('|')), '=', '1'); return result; }