#the key is returning undefined when i try to create a jwt
34 messages ยท Page 1 of 1 (latest)
๐ This post has been indexed in our web forum and will be seen by search engines so other users can find it outside Discord
๐ต๏ธ Your user profile is private by default and won't be visible to users outside Discord, if you want to be visible in the web forum you can add the "Public Profile" role in id:customize
โ
You can mark a message as the answer for your post with Right click -> Apps -> Mark Solution
(if you don't see the option, try refreshing Discord with Ctrl + R)
probably because the session took a long time to load and was already direct to useEffect.
@rapid stag you created a new one - was replying in the previous one
sorry I didn't see your code deeply
so couple of bugs there
so first of all add session to the dependency array of your useEffect
okay
sorry, i thought that, that topic has already been solved another problem, to get more organized I created this
and in your useEffect check session?.user?.id and return; before making axios call
yeah, exactly
now nothing happens, apparently it stops at the if(!token) return null
first of all see your backend console if you are getting correct api request
@rapid stag
not much following you
plz be clear at your communication as I am not familar with your codebase
basically, user.id returns undefined and profile.id returns the user id
oh I see so it should be session.profile.id instead of session.user.id
sorry anything, I don't speak English very well, I'm using google translator
yes, I switched and it worked, incredible as it may seem
i will mark as resolved, thank you again!
sure then close this thread
oh, ok
๐