From caa34c6f790f5fa1820a52ed7dc3ebc3dd38e055 Mon Sep 17 00:00:00 2001 From: Harmon Date: Sat, 13 Feb 2021 16:08:35 -0600 Subject: [PATCH] Stop allowing positional arguments for API.create_block Also improve endpoint parameters order to match Twitter API documentation --- tweepy/api.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tweepy/api.py b/tweepy/api.py index c157f88..8e32ec4 100644 --- a/tweepy/api.py +++ b/tweepy/api.py @@ -771,12 +771,12 @@ class API: ) @payload('user') - def create_block(self, *args, **kwargs): + def create_block(self, **kwargs): """ :reference: https://developer.twitter.com/en/docs/accounts-and-users/mute-block-report-users/api-reference/post-blocks-create """ return self.request( - 'POST', 'blocks/create', *args, endpoint_parameters=( - 'user_id', 'screen_name', 'include_entities', 'skip_status' + 'POST', 'blocks/create', endpoint_parameters=( + 'screen_name', 'user_id', 'include_entities', 'skip_status' ), **kwargs ) -- 2.25.1