Changed some texts
This commit is contained in:
@@ -26,23 +26,23 @@ async def callback_query_sus_allow(app, clb):
|
||||
)
|
||||
)
|
||||
|
||||
@app.on_callback_query(filters.regex("sus_refuse_[\s\S]*"))
|
||||
async def callback_query_sus_refuse(app, clb):
|
||||
@app.on_callback_query(filters.regex("sus_reject_[\s\S]*"))
|
||||
async def callback_query_sus_reject(app, clb):
|
||||
|
||||
fullclb = clb.data.split("_")
|
||||
|
||||
await app.send_message(configGet("admin_group"), locale("sus_refused_by", "message").format(clb.from_user.first_name, fullclb[2]), disable_notification=True)
|
||||
logWrite(f"User {fullclb[2]} was refused to join with another link by {clb.from_user.id}")
|
||||
await app.send_message(configGet("admin_group"), locale("sus_rejected_by", "message").format(clb.from_user.first_name, fullclb[2]), disable_notification=True)
|
||||
logWrite(f"User {fullclb[2]} was rejected to join with another link by {clb.from_user.id}")
|
||||
|
||||
edited_markup = [[InlineKeyboardButton(text=str(locale("sus_refused", "button")), callback_data="nothing")]]
|
||||
edited_markup = [[InlineKeyboardButton(text=str(locale("sus_rejected", "button")), callback_data="nothing")]]
|
||||
|
||||
await clb.message.edit(text=clb.message.text, reply_markup=InlineKeyboardMarkup(edited_markup))
|
||||
await clb.answer(text=locale("sus_refused", "callback").format(fullclb[2]), show_alert=True)
|
||||
await clb.answer(text=locale("sus_rejected", "callback").format(fullclb[2]), show_alert=True)
|
||||
|
||||
await app.ban_chat_member(configGet("destination_group"), int(fullclb[2]))
|
||||
|
||||
jsonSave(jsonLoad(f"{configGet('data', 'locations')}{sep}user_default.json"), f"{configGet('data', 'locations')}{sep}users{sep}{fullclb[2]}.json")
|
||||
configSet(["stage"], 10, file=fullclb[2])
|
||||
configSet(["refused"], True, file=fullclb[2])
|
||||
configSet(["refused_by"], clb.from_user.id, file=fullclb[2])
|
||||
configSet(["rejected"], True, file=fullclb[2])
|
||||
configSet(["rejected_by"], clb.from_user.id, file=fullclb[2])
|
||||
# ==============================================================================================================================
|
Reference in New Issue
Block a user