firebase auth.currentUser undefined in middleware
Unanswered
Danna posted this in #help-forum
![Avatar](https://cdn.discordapp.com/avatars/136879578839777280/b7020a06137b247ef8199c3ba79de8aa.webp?size=256)
DannaOP
Hi - so I'm currently logging in my user via google with firebase.
In my useclient files I can simply console log the current user
Now if I check try this
In my middleware I just get undefined.
Is there a way to deal with this?
In my useclient files I can simply console log the current user
Now if I check try this
console.log(auth.currentUser?.displayName);
In my middleware I just get undefined.
Is there a way to deal with this?
1 Reply
![Avatar](https://cdn.discordapp.com/avatars/136879578839777280/b7020a06137b247ef8199c3ba79de8aa.webp?size=256)
DannaOP
just did some googling and stumpled upon nextauth.js ... am I forced to use that perhaps?