mirror of
https://github.com/PaiGramTeam/MibooGram.git
synced 2024-11-16 04:45:27 +00:00
✨ Support privacy policy
This commit is contained in:
parent
fe08fce69a
commit
1841e60f6d
@ -39,6 +39,7 @@ class SetCommandPlugin(Plugin):
|
||||
BotCommand("setcookie", "添加/重设Cookie"),
|
||||
BotCommand("player", "管理用户绑定玩家"),
|
||||
BotCommand("verify", "手动验证"),
|
||||
BotCommand("privacy", "隐私政策"),
|
||||
]
|
||||
group_command = [
|
||||
# 通用
|
||||
|
@ -1,4 +1,5 @@
|
||||
from telegram import Update, ReplyKeyboardRemove
|
||||
from telegram.constants import ParseMode
|
||||
from telegram.ext import CallbackContext, CommandHandler
|
||||
from telegram.helpers import escape_markdown
|
||||
|
||||
@ -36,3 +37,11 @@ class StartPlugin(Plugin):
|
||||
@handler(CommandHandler, command="reply_keyboard_remove", block=False)
|
||||
async def reply_keyboard_remove(self, update: Update, _: CallbackContext) -> None:
|
||||
await update.message.reply_text("移除远程键盘成功", reply_markup=ReplyKeyboardRemove())
|
||||
|
||||
@handler.command(command="privacy", block=False)
|
||||
async def reply_privacy_policy(self, update: "Update", _: "CallbackContext"):
|
||||
message = update.effective_message
|
||||
await message.reply_text(
|
||||
"请查看[PaiGramTeam Bot 用户个人信息及隐私保护政策](https://telegra.ph/paigramteam-bot-privacy-08-02)",
|
||||
parse_mode=ParseMode.MARKDOWN_V2,
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user