feat: set dir for storages

This commit is contained in:
krau
2025-02-25 16:17:20 +08:00
parent d6f8603656
commit 9e776b22fb
18 changed files with 443 additions and 189 deletions

View File

@@ -22,6 +22,11 @@ func FloodWaitMiddleware() []telegram.Middleware {
}
}
const noPermissionText string = `
您不在白名单中, 无法使用此 Bot.
您可以部署自己的实例: https://github.com/krau/SaveAny-Bot
`
func checkPermission(ctx *ext.Context, update *ext.Update) error {
userID := update.GetUserChat().GetID()
if !slice.Contain(config.Cfg.GetUsersID(), userID) {