Commit 1b2d1d9
committed
🚨 CRITICAL FIX: Firebase Admin undefined error in token allocations API
ISSUE: TypeError: Cannot read properties of undefined (reading 'collection')
ROOT CAUSE: Incorrect destructuring of getFirebaseAdmin() return value
FIXES:
✅ Fixed Firebase Admin usage in token allocations route
✅ Added null check for admin instance
✅ Changed from {adminDb} destructuring to direct admin.firestore() call
This was blocking page loads for users with token allocations.1 parent 605299a commit 1b2d1d9
1 file changed
+5
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
110 | 110 | | |
111 | 111 | | |
112 | 112 | | |
113 | | - | |
114 | | - | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
115 | 118 | | |
116 | 119 | | |
117 | 120 | | |
| |||
0 commit comments