-
Bug
-
Resolution: Fixed
-
Low
-
None
-
1
-
Severity 3 - Minor
-
Issue Summary
Widget is not loading on the webpage for few users and gives below error during initialisation:
Uncaught SyntaxError: Unexpected non-whitespace character after JSON at position 4 at JSON.parse (<anonymous>) at jt.getAnonymousId (user.js:39:35)
Steps to Reproduce
- Set invalid (without encoded quotes) `ajs_anonymous_id` cookie with date expiration on app root domain (i. e. `document.cookie = "ajs_anonymous_id=<anonymous-id>; domain=***.com; expires='Thu, 20 Jun 2024 11:36:45 GMT'"`)
- Make sure `ajs_anonymous_id` is not set in local storage (as it is preferred source)
- Refresh page and observe the error and widget will not load
Expected Results
- It should load the widget without any error even if the cookie is passed without quotes.
Actual Results
- Widget is not loading for few users where cookie is passed without quotes from browser.
Workaround
Currently there is no known workaround for this behavior. A workaround will be added here when available