1
0
mirror of https://github.com/eternnoir/pyTelegramBotAPI.git synced 2023-08-10 21:12:57 +03:00

Add missing arg until_date for kickChatMember.

This commit is contained in:
eternnoir
2017-07-01 11:11:25 +08:00
parent 514880fe22
commit 5f8ed347a1
2 changed files with 7 additions and 3 deletions

View File

@ -420,9 +420,11 @@ def get_method_by_type(data_type):
return r'sendSticker'
def kick_chat_member(token, chat_id, user_id):
def kick_chat_member(token, chat_id, user_id, until_date=None):
method_url = 'kickChatMember'
payload = {'chat_id': chat_id, 'user_id': user_id}
if until_date:
payload['until_date'] = until_date
return _make_request(token, method_url, params=payload, method='post')