Nakama failed Update username

currently working on game nakama able to generate username we want to update the
username that has been generate by nakama. we have handle that by using session refresh but sometimes the approach wont work. i have debug to check the username before the session get refreshed and after. before the refreshing the session i check the username it was the one that generate by nakama but after refresh it remind the same. i have used try and catch to handle that i could not reach solution

Nakama uses the session token as an edge cache for small pieces of frequently accessed information. If the user changes their username make sure to disconnect, log them out, and re-authenticate/re-connect. Note that a session refresh may not be sufficient, you should re-authenticate instead.

as we know nakama generate username by default it seem something like that “qiwVUrGrfu” we tried to update username.

the one that we generate.

this approach sometimes it works sometimes fail to update