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

After unstaking everything, Dashboard > My Courts is not empty #1176

Closed
jaybuidl opened this issue Aug 22, 2023 · 1 comment · Fixed by #1169
Closed

After unstaking everything, Dashboard > My Courts is not empty #1176

jaybuidl opened this issue Aug 22, 2023 · 1 comment · Fixed by #1169
Labels
Package: Web Court web frontend Type: Bug 🐛 Type: UX User Experience
Milestone

Comments

@jaybuidl
Copy link
Member

jaybuidl commented Aug 22, 2023

image

The subgraph response is actually different for someone who has never staked (it returns null) compared to someone who has unstaked everything.

image image
@jaybuidl
Copy link
Member Author

Never staked

{
  "data": {
    "user": null
  }
}

Staked

{
  "data": {
    "user": {
      "tokens": [
        {
          "court": {
            "id": "1",
            "name": "General Court"
          },
          "staked": "40000000000000000000000",
          "locked": "0",
          "delayed": "0"
        }
      ],
      "totalStake": "40000000000000000000000",
      "totalDelayed": "0",
      "totalDisputes": "0"
    }
  }
}

Unstaked all

{
  "data": {
    "user": {
      "tokens": [
        {
          "court": {
            "id": "1",
            "name": "General Court"
          },
          "staked": "0",
          "locked": "0",
          "delayed": "0"
        }
      ],
      "totalStake": "0",
      "totalDelayed": "0",
      "totalDisputes": "0"
    }
  }
}

Request

{
  user(id: "0x...") {
    tokens {
      court {
        id
        name
      }
      staked
      locked
      delayed
    }
    totalStake
    totalDelayed  
    totalDisputes
  }
}

@kemuru kemuru linked a pull request Aug 28, 2023 that will close this issue
@jaybuidl jaybuidl added this to the testnet-2 milestone Oct 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Package: Web Court web frontend Type: Bug 🐛 Type: UX User Experience
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant