-
Notifications
You must be signed in to change notification settings - Fork 16
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
Restore leaderboards #250
Restore leaderboards #250
Conversation
If leaderboard change is successful, frontend will probably want the leaderboard returned with the changes instead of a NoContent; They will likely have to update a local cache/store - so this is better than making another request. |
2ea53b0
to
3041388
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we forgot to cover the case where the board can't be restored because its slug has been reclaimed by another board. Shall we simply have it return a 409 and possibly the conflicting board or at least the ID of the conflicting board?
409'ing sounds fair. I should add that in. I'll return the full board; better visibility that way. |
Is this even possible? |
We decided that deleted LBs should get excluded from the unique index for slugs. This is achieved by filtering the index to only cover LBs that are not deleted. This means that when you delete an LB, its slug is freed. Alternatively, we could ask for a slug to use when restoring the LB to prevent the annoying and confusing case of having to give a deleted LB new slug before you restore it. In addition or perhaps instead, we could have it so that deleting a board automatically clears its slug. |
Reflecting what I've said on Discord; I won't be implementing the ability to pass a new slug in to restore a board, nor am I clearing a board's slug on deletion. If a board conflicts, it conflicts. |
3418ea1
to
eb1b053
Compare
Closes: #240
I do not know how to write these dang tests.I now do know how to write these dang tests.