Skip to content
This repository has been archived by the owner on Jun 24, 2022. It is now read-only.

Commit

Permalink
update Gorm log import
Browse files Browse the repository at this point in the history
  • Loading branch information
Aoang committed Dec 4, 2021
1 parent 8bc5703 commit c3f5c51
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gorm.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ type GormLogger struct {
IgnoreRecordNotFoundError bool
}

func NewGormLogger() *GormLogger {
func Gorm(l *zap.Logger) *GormLogger {
return &GormLogger{
log: With("gorm log"),
log: l,
Level: zap.WarnLevel,
SlowThreshold: 100 * time.Millisecond,
SkipCallerLookup: false,
Expand Down

0 comments on commit c3f5c51

Please sign in to comment.