Skip to content
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

[functions]: v2 change events and creation shapshots not referencing named database it was triggered on #6971

Closed
SupposedlySam opened this issue Apr 5, 2024 · 1 comment · Fixed by firebase/firebase-functions#1550

Comments

@SupposedlySam
Copy link

SupposedlySam commented Apr 5, 2024

[REQUIRED] Environment info

firebase-tools:

13.6.1

Platform:

macOS

[REQUIRED] Steps to reproduce

  • Create a Firebase project with a named database called dev
  • Create a v2 Firebase Function for onDocumentCreated
  • Create a Document on the dev database at the path you defined your function for
  • Use the snapshot.ref.firestore accessor and check whether it's pointing to the dev database

[REQUIRED] Expected behavior

The database name should be dev

[REQUIRED] Actual behavior

The database name is (default)

If you actually try to use the ref to delete it, it will yell at you and tell you you're trying to access a different database.

For instance try, snapshot.ref.delete().

@google-oss-bot
Copy link
Contributor

This issue does not seem to follow the issue template. Make sure you provide all the required information.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants