1
0

Formatting

This commit is contained in:
Akbar Rahman 2018-08-16 20:10:36 +01:00
parent 1901de893d
commit 7ab29c7533
Signed by: alvierahman90
GPG Key ID: 20609519444A1269

8
bot.py
View File

@ -1,5 +1,9 @@
#!/usr/bin/env python3
# coding=utf-8
"""
The bot script
Run this, I guess
"""
import re
import json
@ -58,7 +62,7 @@ def process_command(command, arguments, chat_id):
if command == '/start':
user_init(chat_id)
elif command == '/help':
user_help_info(chat_id, arguments=arguments)
user_help_info(chat_id)
elif command == '/add':
add_task(Task(" ".join(arguments)), chat_id)
elif command == '/rm':
@ -358,7 +362,7 @@ def user_init(chat_id):
BOT.sendMessage(chat_id, "Welcome to todo.txt but as a Telegram bot. Run"
" /help to get started")
def user_help_info(chat_id, arguments=None):
def user_help_info(chat_id):
"""
The help text sent to user
:param chat_id: Telegram chat_id