Skip to content

Commit

Permalink
Fix examples (#16)
Browse files Browse the repository at this point in the history
  • Loading branch information
lnnt authored Mar 22, 2024
1 parent 35ed30b commit ecefaa5
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,9 @@ func (c *redisCacher) Invalidate(ctx context.Context) error {
}

func main() {
db, _ := gorm.Open(sqlite.Open("gorm.db"), &gorm.Config{})
db, _ := gorm.Open(sqlite.Open("gorm.db"), &gorm.Config{
AllowGlobalUpdate: true,
})

cachesPlugin := &caches.Caches{Conf: &caches.Config{
Cacher: &redisCacher{
Expand Down Expand Up @@ -333,7 +335,9 @@ func (c *memoryCacher) Invalidate(ctx context.Context) error {
}

func main() {
db, _ := gorm.Open(sqlite.Open("gorm.db"), &gorm.Config{})
db, _ := gorm.Open(sqlite.Open("gorm.db"), &gorm.Config{
AllowGlobalUpdate: true,
})

cachesPlugin := &caches.Caches{Conf: &caches.Config{
Cacher: &memoryCacher{},
Expand Down

0 comments on commit ecefaa5

Please sign in to comment.