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

Update README.md #47

Merged
merged 1 commit into from
Jun 9, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions gorm/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ db, err := gorm.Open(mysql.Open(dsn), &gorm.Config{})
if err != nil {
log.Fatalf("open db error: %v \n", err)
}
db.Use(gormPlugin.New(tracer, "127.0.0.1:3306", gormPlugin.MYSQL))
db.Use(gormPlugin.New(tracer, gormPlugin.WithPeerAddr("127.0.0.1:3306"), gormPlugin.WithSqlDBType(gormPlugin.MYSQL)))

// use with context
dbWithCtx := db.WithContext(ctx)
```
```(