fix(with): 修复 memory.go 中的配置初始化错误

将 bigcache.Config 结构体实例改为指针传递,确保配置能够正确初始化和传递。
This commit is contained in:
yanweidong 2025-09-20 11:32:24 +08:00
parent 257f0a6b6e
commit f70f8d94db
1 changed files with 1 additions and 1 deletions

View File

@ -11,7 +11,7 @@ import (
func Memory(cli *bigcache.BigCache, opts *bigcache.Config) {
if opts == nil {
opts = bigcache.Config{
opts = &bigcache.Config{
Shards: 1024,
LifeWindow: 10 * time.Minute,
CleanWindow: 5 * time.Minute,