mirror of
https://github.com/FloatTech/ZeroBot-Plugin.git
synced 2026-02-11 17:50:25 +00:00
🎨 优化目录结构
This commit is contained in:
16
plugin/reborn/load.go
Normal file
16
plugin/reborn/load.go
Normal file
@@ -0,0 +1,16 @@
|
||||
package reborn
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
|
||||
"github.com/FloatTech/zbputils/file"
|
||||
)
|
||||
|
||||
// load 加载rate数据
|
||||
func load(area *rate, jsonfile string) error {
|
||||
data, err := file.GetLazyData(jsonfile, true, true)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return json.Unmarshal(data, area)
|
||||
}
|
||||
Reference in New Issue
Block a user