summaryrefslogtreecommitdiff
path: root/internal/db/basic.go
diff options
context:
space:
mode:
authorLibravatar kim <89579420+NyaaaWhatsUpDoc@users.noreply.github.com>2023-08-17 17:26:21 +0100
committerLibravatar tsmethurst <tobi.smethurst@protonmail.com>2023-08-21 17:17:38 +0200
commit45334581cad04e45dec3a5037f997e2ecc6d30b0 (patch)
tree44df2eaf48eca66023023569d4ba8d901d800226 /internal/db/basic.go
parent[chore]: Bump github.com/jackc/pgx/v5 from 5.4.2 to 5.4.3 (#2112) (diff)
downloadgotosocial-45334581cad04e45dec3a5037f997e2ecc6d30b0.tar.xz
[bugfix] fix double firing bun.DB query hooks (#2124)
* improve bun.DB wrapping readability + comments, fix double-firing query hooks * fix incorrect code comment placement * fix linter issues * Update internal/db/basic.go * do as the linter commmands ... --------- Signed-off-by: kim <grufwub@gmail.com> Co-authored-by: Daenney <daenney@users.noreply.github.com>
Diffstat (limited to 'internal/db/basic.go')
-rw-r--r--internal/db/basic.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/db/basic.go b/internal/db/basic.go
index f8c04c6b9..7cd690aef 100644
--- a/internal/db/basic.go
+++ b/internal/db/basic.go
@@ -33,9 +33,9 @@ type Basic interface {
// For implementations that don't use tables, this can just return nil.
DropTable(ctx context.Context, i interface{}) error
- // Stop should stop and close the database connection cleanly, returning an error if this is not possible.
+ // Close should stop and close the database connection cleanly, returning an error if this is not possible.
// If the database implementation doesn't need to be stopped, this can just return nil.
- Stop(ctx context.Context) error
+ Close() error
// IsHealthy should return nil if the database connection is healthy, or an error if not.
IsHealthy(ctx context.Context) error