mirror of
https://github.com/FloatTech/ZeroBot-Plugin.git
synced 2025-12-19 05:30:07 +08:00
🐛 fix fontfile notfound error
This commit is contained in:
parent
790200e519
commit
b676e00f0b
2
go.mod
2
go.mod
@ -3,7 +3,7 @@ module github.com/FloatTech/ZeroBot-Plugin
|
||||
go 1.17
|
||||
|
||||
require (
|
||||
github.com/FloatTech/AnimeAPI v1.2.1
|
||||
github.com/FloatTech/AnimeAPI v1.2.2
|
||||
github.com/FloatTech/zbputils v1.2.3-add9
|
||||
github.com/antchfx/htmlquery v1.2.4
|
||||
github.com/corona10/goimagehash v1.0.3
|
||||
|
||||
4
go.sum
4
go.sum
@ -1,5 +1,5 @@
|
||||
github.com/FloatTech/AnimeAPI v1.2.1 h1:G7bVAYlvt+pT9Kfu1zEF5cXAd1nmNDD1nHnnq1pnph4=
|
||||
github.com/FloatTech/AnimeAPI v1.2.1/go.mod h1:kizVlcmBE2Pr2FGmC7H+xfyhyvUXTOibXaqBTQAnY3U=
|
||||
github.com/FloatTech/AnimeAPI v1.2.2 h1:Og3rLtsC/5k2elJ38/ux9wITJJDT7nUylsJOqmNpZ4E=
|
||||
github.com/FloatTech/AnimeAPI v1.2.2/go.mod h1:kizVlcmBE2Pr2FGmC7H+xfyhyvUXTOibXaqBTQAnY3U=
|
||||
github.com/FloatTech/bot-manager v1.0.0/go.mod h1:8YYRJ16oroGHQGD2En0oVnmcKJkxR9O/jd5BPSfWfOQ=
|
||||
github.com/FloatTech/zbputils v1.2.3-add8/go.mod h1:ZIuQP4tuhn7jiowEy+PALiHmr4zzPQBj4VdjEyd5/Es=
|
||||
github.com/FloatTech/zbputils v1.2.3-add9 h1:lovWc7uvaqSww1TV8/BlGZNf5o2jBUgU4VIlXCusgrI=
|
||||
|
||||
@ -5,7 +5,9 @@ import (
|
||||
|
||||
log "github.com/sirupsen/logrus"
|
||||
|
||||
"github.com/FloatTech/zbputils/file"
|
||||
"github.com/FloatTech/zbputils/process"
|
||||
"github.com/FloatTech/zbputils/txt2img"
|
||||
)
|
||||
|
||||
const (
|
||||
@ -21,6 +23,14 @@ var sdb *scoredb
|
||||
func init() {
|
||||
go func() {
|
||||
process.SleepAbout1sTo2s()
|
||||
_, err := file.GetLazyData(txt2img.BoldFontFile, false, true)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
_, err = file.GetLazyData(txt2img.FontFile, false, true)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
_ = os.MkdirAll(dbpath, 0755)
|
||||
os.RemoveAll(cachePath)
|
||||
_ = os.MkdirAll(cachePath, 0755)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user