Skip to content

Commit

Permalink
fix: db
Browse files Browse the repository at this point in the history
  • Loading branch information
moocss committed Aug 23, 2024
1 parent c3bac4b commit ee279cf
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions db/gorm/wrapper.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ type Transaction interface {
Execute(ctx context.Context, fn func(ctx context.Context) error) error
}

type DB = gorm.DB

type Helper struct {
lock *sync.RWMutex
group *singleflight.Group
Expand Down
4 changes: 4 additions & 0 deletions db/redis/wrapper.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ import (
var _ Database = (*Helper)(nil)

type (
// Cmdable is an alias of redis.Cmdable.
Cmdable = redis.Cmdable
// BoolCmd is an alias of redis.BoolCmd.
BoolCmd = redis.BoolCmd
// IntCmd is an alias of redis.IntCmd.
IntCmd = redis.IntCmd
// FloatCmd is an alias of redis.FloatCmd.
Expand Down

0 comments on commit ee279cf

Please sign in to comment.