fix: Bot の Access Token が revoke されても bot の detail を見れるようにする#2814
Open
fix: Bot の Access Token が revoke されても bot の detail を見れるようにする#2814
Conversation
0540448 to
0d1a44f
Compare
6ecd6bc to
351126b
Compare
Takeno-hito
reviewed
Nov 7, 2025
|
|
||
| _, err = env.Repository.GetTokenByID(token.ID) | ||
| assert.EqualError(t, err, repository.ErrNotFound.Error()) | ||
| d, err := env.Repository.GetTokenByIDWithDeleted(token.ID) |
Member
There was a problem hiding this comment.
GetTokenByID では error が変わらず返ってくることは試してほしいかも(細かい話をいうと本当はここの責務ではない気もするんだけど)
| } | ||
|
|
||
| t, err := h.Repo.GetTokenByID(b.AccessTokenID) | ||
| t, err := h.Repo.GetTokenByIDWithDeleted(b.AccessTokenID) |
Member
There was a problem hiding this comment.
bots_test.go に Token が Deleted 状態だったらしっかりレスポンスも Revoked true になってるかをチェックするコードを入れてほしい!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
close: #2813