mirror of
https://github.com/FloatTech/ZeroBot-Plugin.git
synced 2025-12-19 13:59:39 +08:00
fix: panic: database is locked (5) (SQLITE_BUSY)
This commit is contained in:
parent
2858d0b0a4
commit
ce8d98b77d
@ -67,17 +67,17 @@ var (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func init() { // 插件主体
|
func init() { // 插件主体
|
||||||
|
engine := control.Register("setutime", &control.Options{
|
||||||
|
DisableOnDefault: false,
|
||||||
|
Help: "涩图\n" +
|
||||||
|
"- 来份[涩图/二次元/风景/车万]\n" +
|
||||||
|
"- 添加[涩图/二次元/风景/车万][P站图片ID]\n" +
|
||||||
|
"- 删除[涩图/二次元/风景/车万][P站图片ID]\n" +
|
||||||
|
"- >setu status",
|
||||||
|
})
|
||||||
go func() {
|
go func() {
|
||||||
process.SleepAbout1sTo2s()
|
process.SleepAbout1sTo2s()
|
||||||
pool = newPools()
|
pool = newPools()
|
||||||
engine := control.Register("setutime", &control.Options{
|
|
||||||
DisableOnDefault: false,
|
|
||||||
Help: "涩图\n" +
|
|
||||||
"- 来份[涩图/二次元/风景/车万]\n" +
|
|
||||||
"- 添加[涩图/二次元/风景/车万][P站图片ID]\n" +
|
|
||||||
"- 删除[涩图/二次元/风景/车万][P站图片ID]\n" +
|
|
||||||
"- >setu status",
|
|
||||||
})
|
|
||||||
engine.OnRegex(`^来份(.*)$`, rule.FirstValueInList(pool.List)).SetBlock(true).SetPriority(20).
|
engine.OnRegex(`^来份(.*)$`, rule.FirstValueInList(pool.List)).SetBlock(true).SetPriority(20).
|
||||||
Handle(func(ctx *zero.Ctx) {
|
Handle(func(ctx *zero.Ctx) {
|
||||||
if !limit.Load(ctx.Event.UserID).Acquire() {
|
if !limit.Load(ctx.Event.UserID).Acquire() {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user