summaryrefslogtreecommitdiff
path: root/internal/db/application.go
diff options
context:
space:
mode:
authorLibravatar kim <89579420+NyaaaWhatsUpDoc@users.noreply.github.com>2025-01-27 15:54:59 +0000
committerLibravatar GitHub <noreply@github.com>2025-01-27 15:54:59 +0000
commit726d2ba483b58402fa5e8d5a99d5cbd290bdeb67 (patch)
treeec597aa14d4c5cd8f36661750ff71a3ffbc2eb2d /internal/db/application.go
parentbumps uptrace/bun deps to v1.2.8 (#3698) (diff)
downloadgotosocial-726d2ba483b58402fa5e8d5a99d5cbd290bdeb67.tar.xz
[chore] some tidy ups (#3677)
* small formatting changes (no logic) * improve code comments * fix import cycle * shutup stinky linter
Diffstat (limited to 'internal/db/application.go')
-rw-r--r--internal/db/application.go26
1 files changed, 13 insertions, 13 deletions
diff --git a/internal/db/application.go b/internal/db/application.go
index 5a4068431..1011698bf 100644
--- a/internal/db/application.go
+++ b/internal/db/application.go
@@ -36,42 +36,42 @@ type Application interface {
// DeleteApplicationByClientID deletes the application with corresponding client_id value from the database.
DeleteApplicationByClientID(ctx context.Context, clientID string) error
- // GetClientByID ...
+ // GetClientByID fetches the application client from database with ID.
GetClientByID(ctx context.Context, id string) (*gtsmodel.Client, error)
- // PutClient ...
+ // PutClient puts the given application client in the database.
PutClient(ctx context.Context, client *gtsmodel.Client) error
- // DeleteClientByID ...
+ // DeleteClientByID deletes the application client from database with ID.
DeleteClientByID(ctx context.Context, id string) error
- // GetAllTokens ...
+ // GetAllTokens fetches all client oauth tokens from database.
GetAllTokens(ctx context.Context) ([]*gtsmodel.Token, error)
- // GetTokenByID ...
+ // GetTokenByID fetches the client oauth token from database with ID.
GetTokenByID(ctx context.Context, id string) (*gtsmodel.Token, error)
- // GetTokenByCode ...
+ // GetTokenByCode fetches the client oauth token from database with code.
GetTokenByCode(ctx context.Context, code string) (*gtsmodel.Token, error)
- // GetTokenByAccess ...
+ // GetTokenByAccess fetches the client oauth token from database with access code.
GetTokenByAccess(ctx context.Context, access string) (*gtsmodel.Token, error)
- // GetTokenByRefresh ...
+ // GetTokenByRefresh fetches the client oauth token from database with refresh code.
GetTokenByRefresh(ctx context.Context, refresh string) (*gtsmodel.Token, error)
- // PutToken ...
+ // PutToken puts given client oauth token in the database.
PutToken(ctx context.Context, token *gtsmodel.Token) error
- // DeleteTokenByID ...
+ // DeleteTokenByID deletes client oauth token from database with ID.
DeleteTokenByID(ctx context.Context, id string) error
- // DeleteTokenByCode ...
+ // DeleteTokenByCode deletes client oauth token from database with code.
DeleteTokenByCode(ctx context.Context, code string) error
- // DeleteTokenByAccess ...
+ // DeleteTokenByAccess deletes client oauth token from database with access code.
DeleteTokenByAccess(ctx context.Context, access string) error
- // DeleteTokenByRefresh ...
+ // DeleteTokenByRefresh deletes client oauth token from database with refresh code.
DeleteTokenByRefresh(ctx context.Context, refresh string) error
}