Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Token being appended multiple times #185

Open
PeterPilley opened this issue Jun 13, 2024 · 0 comments
Open

Token being appended multiple times #185

PeterPilley opened this issue Jun 13, 2024 · 0 comments

Comments

@PeterPilley
Copy link

Environment



Reproduction

Follow this tutorial for implementation
https://authjs-nuxt.pages.dev/usage.html

Describe the bug

I have implemented your module, but when I test the session data I can see token is being appended again every time the page refreshes, I cant work out why it is doing it

  "session": {
    "user": {},
    "expires": "2024-07-13T09:59:46.600Z"
  },
  "token": {
    "token": {
      "token": {
        "token": {
          "token": {
            "token": {
              "token": {
                "token": {
                  "name": "User Name",
                  "email": "[email protected]",
                  "sub": "87f1c6f8-ef32-47c9-9cc9-c302e4f97cf4"
                },
                "user": {
                  "id": "87f1c6f8-ef32-47c9-9cc9-c302e4f97cf4",
                  "name": "Fake Org"

### Additional context

I am using these as callbacks

async jwt(token, user, account, profile, isNewUser) {
if (account) {
token.accessToken = account.accessToken
}
return token

	},

async session(session, user, token) {
return session
}


### Logs

_No response_
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant