From: Harmon Date: Wed, 29 Sep 2021 05:22:45 +0000 (-0500) Subject: Stop checking Client request parameter name when converting to datetime X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=1320a3709b1683cb32b69abdaa9e7e120b6ed59c;p=tweepy.git Stop checking Client request parameter name when converting to datetime --- diff --git a/tweepy/client.py b/tweepy/client.py index e3b445b..1077e17 100644 --- a/tweepy/client.py +++ b/tweepy/client.py @@ -143,7 +143,7 @@ class Client: if isinstance(param_value, list): request_params[param_name] = ','.join(map(str, param_value)) - elif param_name in ("start_time", "end_time") and isinstance(param_value, datetime.datetime): + elif isinstance(param_value, datetime.datetime): if param_value.tzinfo is not None: param_value = param_value.astimezone(datetime.timezone.utc) request_params[param_name] = param_value.strftime("%Y-%m-%dT%H:%M:%S.%fZ")