```
refactor(with): 调整Memory函数参数顺序 将Memory函数的参数顺序从(opts, cli)调整为(cli, opts), 使函数签名更加符合常规的客户端优先参数排列习惯, 提升代码可读性和一致性。 ```
This commit is contained in:
parent
b9d144353e
commit
4f584726d6
|
@ -10,7 +10,7 @@ import (
|
||||||
"github.com/allegro/bigcache/v3"
|
"github.com/allegro/bigcache/v3"
|
||||||
)
|
)
|
||||||
|
|
||||||
func Memory(opts *bigcache.Config, cli *bigcache.BigCache) {
|
func Memory(cli *bigcache.BigCache, opts *bigcache.Config) {
|
||||||
config := bigcache.Config{
|
config := bigcache.Config{
|
||||||
Shards: 1024,
|
Shards: 1024,
|
||||||
LifeWindow: 10 * time.Minute,
|
LifeWindow: 10 * time.Minute,
|
||||||
|
|
Loading…
Reference in New Issue