Compare commits

..

2 Commits

Author SHA1 Message Date
justuser-31 e7751829ff Add: requirements and gitignore 2026-06-11 09:29:20 +00:00
justuser-31 4c3263af28 Fix: small changes 2026-06-11 09:29:20 +00:00
3 changed files with 12 additions and 6 deletions
+3
View File
@@ -0,0 +1,3 @@
__pycache__
*.json
+7 -6
View File
@@ -330,12 +330,13 @@ def setwelcome(message):
@bot.message_handler(commands=['welcome']) @bot.message_handler(commands=['welcome'])
def welcome(message): def welcome(message):
try: try:
db = read_db() db = read_db()
bot.reply_to(message, f'''Приветственное сообщение: bot.reply_to(message, f'''Приветственное сообщение:
\n{db[str(message.chat.id)]}''', parse_mode='HTML') \n{db[str(message.chat.id)]}''', parse_mode='HTML')
except Exception as e: print(db[str(message.chat.id)])
catch_error(message, e) except Exception as e:
catch_error(message, e)
@bot.message_handler(commands=['lock']) @bot.message_handler(commands=['lock'])
def lock(message): def lock(message):
@@ -379,7 +380,7 @@ def delete(message):
def pin(message): def pin(message):
try: try:
if have_rights(message): if have_rights(message):
bot.pin_chat_message(message.chat.id, message.reply_to_message.id) bot.pin_chat_message(message.chat.id, message.reply_to_message.id, disable_notification=False)
except: except:
catch_error(message, e) catch_error(message, e)
+2
View File
@@ -0,0 +1,2 @@
xxhash
pytelegrambotapi