Skip to content

Fix 'window is not defined' error when calling clearIndexedDbPersistence #8888

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 1, 2025

Conversation

milaGGL
Copy link
Contributor

@milaGGL milaGGL commented Apr 1, 2025

Fixes #6465

Call the "indexedDb" on self/window/global based on availability.

@milaGGL milaGGL requested review from a team as code owners April 1, 2025 14:13
Copy link

changeset-bot bot commented Apr 1, 2025

🦋 Changeset detected

Latest commit: cdc7c50

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 3 packages
Name Type
@firebase/firestore Patch
firebase Patch
@firebase/firestore-compat Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@google-oss-bot
Copy link
Contributor

Size Report 1

Affected Products

  • @firebase/firestore

    TypeBase (933ba9d)Merge (4a48bb1)Diff
    browser382 kB382 kB+22 B (+0.0%)
    main591 kB591 kB+32 B (+0.0%)
    module382 kB382 kB+22 B (+0.0%)
    react-native382 kB382 kB+18 B (+0.0%)
  • bundle

    TypeBase (933ba9d)Merge (4a48bb1)Diff
    firestore (CSI Auto Indexing Disable and Delete)272 kB272 kB-3 B (-0.0%)
    firestore (CSI Auto Indexing Enable)272 kB272 kB-3 B (-0.0%)
    firestore (Persistence)304 kB304 kB-3 B (-0.0%)
    firestore (Read Write w Persistence)328 kB328 kB-3 B (-0.0%)
  • firebase

    TypeBase (933ba9d)Merge (4a48bb1)Diff
    firebase-compat.js794 kB794 kB-3 B (-0.0%)
    firebase-firestore-compat.js340 kB340 kB+6 B (+0.0%)
    firebase-firestore.js440 kB440 kB-36 B (-0.0%)

Test Logs

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/iYX6eha2Lt.html

@google-oss-bot
Copy link
Contributor

Size Analysis Report 1

This report is too large (184,133 characters) to be displayed here in a GitHub comment. Please use the below link to see the full report on Google Cloud Storage.

Test Logs

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/dMAXM46kAx.html

Copy link
Contributor

@MarkDuckworth MarkDuckworth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@milaGGL milaGGL merged commit 88a8055 into main Apr 1, 2025
44 of 48 checks passed
@milaGGL milaGGL deleted the mila/fix-service-worker-window-undefined-error branch April 1, 2025 20:07
@google-oss-bot google-oss-bot mentioned this pull request Apr 22, 2025
@firebase firebase locked and limited conversation to collaborators May 2, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

clearIndexedDbPersistence gives 'window is not defined' error in service worker
3 participants