🌐 i18n config file [skip ci]

This commit is contained in:
naiba
2022-04-28 10:17:38 +08:00
parent 3e5c3c64d0
commit 3d2d116100
10 changed files with 19 additions and 11 deletions

View File

@@ -30,7 +30,6 @@ func Init() {
panic(err)
}
Conf = &model.Config{}
Cache = cache.New(5*time.Minute, 10*time.Minute)
}
@@ -43,6 +42,7 @@ func LoadSingleton() {
// InitConfigFromPath 从给出的文件路径中加载配置
func InitConfigFromPath(path string) {
Conf = &model.Config{}
err := Conf.Read(path)
if err != nil {
panic(err)