gladly-team/next-firebase-auth

Why is databaseURL required during init?

Closed this issue · 1 comments

Describe the bug
I'm unable to provide the databaseURL the init function demands because I don't use Firebase's DBs. Passing an empty string silences the error and the library functions seemingly fine. It seems unnecessary for it to be required.

Versions

next-firebase-auth version: 1.0.0-canary.19
Firebase JS SDK: 9.19.1
Next.js: 13.2.1

To Reproduce
Steps to reproduce the behavior:

  1. Call init in a TS file with a firebaseAdminInitConfig that's missing a databaseURL key
  2. Expect a TS error about a missing key

Expected behavior
Firebase auth and the Firebase DB are separate services. next-firebase-auth should not require information about a service that my Firebase project doesn't even use.

Debug and error logs
image

You're right, it shouldn't be required. Firebase docs show databaseURL as optional:

Please feel free to make a PR to update that type!