forked from Pavel_Durov/python_bot
fix session
This commit is contained in:
parent
3dd2b32086
commit
5c7935e430
7
bot.py
7
bot.py
@ -114,9 +114,10 @@ chat_id = message.chat.id)
|
||||
async def send_topchat(message: types.Message):
|
||||
changechat_id = session.query(user).filter(user.user_id == message.from_user.id).first()
|
||||
chats = message.chat.id
|
||||
changechat_id.chat_id = chats
|
||||
session.commit()
|
||||
session.close()
|
||||
if changechat_id.chat_id != chats:
|
||||
changechat_id.chat_id = chats
|
||||
session.commit()
|
||||
session.close()
|
||||
top = session.query(user.user_fullname, user.dick_size).order_by(user.dick_size.desc()).filter(user.chat_id == chats).limit(10).all()
|
||||
|
||||
delimiter = ': '
|
||||
|
Loading…
Reference in New Issue
Block a user