You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
constlemmyClient=newLemmyHttp(`https://${instanceBase}`);constauth=awaitlemmyClient.login({username_or_email: username,password: password,});// as long aws there is a JWT in the response from login, logged in!if(auth.jwt){// this shows the `jwt` is present 👍console.log("auth",auth);// i tried this too, but didn't seem to work :/lemmyClient.setHeaders({Cookie: `jwt=${auth.jwt}`});// this no longer has any paramsconstgetSite=awaitlemmyClient.getSite({auth: auth.jwt,});// but never any user data here :(console.log("getSite",getSite);}
Edit: forgot to mention, this was after upgrading to 0.19.0-rc.13 from 0.18.1
The text was updated successfully, but these errors were encountered:
It seems that we're meant to pass both the form data to ensure backwards-compatability
It should be possible for clients to support both Lemmy 0.18 and 0.19 without major workarounds. If backwards compatibility is causing you trouble, comment below and we will help to find a solution.
I suppose the issue is it means this library isn't backwards-compatible.
Previously, I was passing
auth
togetSite()
in order to fetch the current user and their metadata.It looks like the
formData
param has been removed:ab7af88#r128832008
Is there an alternative way to pass auth in?
example code
Edit: forgot to mention, this was after upgrading to
0.19.0-rc.13
from0.18.1
The text was updated successfully, but these errors were encountered: