If I don't finally find solution I'll send code here
I need to learn more
It returns two io.appwrite.exceptions.AppwriteException: User (role: guests) missing scope (account)
why?
This typically happens when you don't have a session which makes sense because you're calling account.getSession()
before a session is created
In first situation sessionId string is not founded in debug and that's why it don"t work
I need to call deleteSession
later?
no.
when you create a session, you get a session id. or you can call getSession. i don't really understand why you need to store it in shared preferences
....
String newSessionId is getting value from createEmailSession()
But when I going outside createEmailSession newSessionId
value is null and catch's error in first code variation
Of course
I finally understand why problem here
In my code first instruction is account.create()
In account.create()
other data saving code
But this code start compilation when account and Session created
But account.getSession()
and account.deleteSession()
starts work right now
And this is why i catch this error twice
I need to start this code only after account.create()
full compilation
But I need to do it only outside
account.create()
method
I solved this! I add boolean and when boolean == true session deletes
But I need to put it in AsyncTask because app is lagged when account creates
[SOLVED] Error when import java + kotlin sdk
Recommended threads
- The current user is not authorized to pe...
I want to create a document associated with user after log in with OAuth. The user were logged in, but Appwrite said user is unauthorized. User is logged in wi...
- My account is blocked so please check an...
My account is blocked so please unblock my account because all the apps are closed due to which it is causing a lot of problems
- Deep Linking & Password reset
I am using react native with expo. I want to implement deep link with the url recived via email. So when clicked the link it opens my app. I havent ever used de...