Skip to content

fix(seerExplorer): Handle localStorage access in Safari private mode - #121031

Draft
sentry[bot] wants to merge 1 commit into
masterfrom
seer/fix/seer-explorer-localstorage-safari
Draft

fix(seerExplorer): Handle localStorage access in Safari private mode#121031
sentry[bot] wants to merge 1 commit into
masterfrom
seer/fix/seer-explorer-localstorage-safari

Conversation

@sentry

@sentry sentry Bot commented Aug 1, 2026

Copy link
Copy Markdown
Contributor

This PR addresses a TypeError: null is not an object that occurred in Safari's private browsing mode when accessing localStorage directly within seerExplorerSidebarLayout.tsx.

In Safari private mode, window.localStorage returns null, causing direct calls to localStorage.getItem and localStorage.setItem to fail. The fix replaces these direct calls on lines 70 and 99 with localStorageWrapper from sentry/utils/localStorage, which is designed to safely handle environments where localStorage might be unavailable or restricted.

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

Fixes JAVASCRIPT-3AX3

Comment @sentry <feedback> on this PR to have Autofix iterate on the changes.

@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Aug 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants