From 649b6cabe0a324bce5b777e22d1acaeae2c87aaf Mon Sep 17 00:00:00 2001 From: adbenitez Date: Thu, 24 Nov 2022 14:53:36 -0500 Subject: fix NameError: name 'x' is not defined in __json_date_parse() --- mastodon/Mastodon.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mastodon/Mastodon.py b/mastodon/Mastodon.py index f0d9cc5..2cb125f 100644 --- a/mastodon/Mastodon.py +++ b/mastodon/Mastodon.py @@ -3569,7 +3569,7 @@ class Mastodon: else: json_object[k] = dateutil.parser.parse(v) except: - if isinstance(v, str) and len(x.strip()) == 0: + if isinstance(v, str) and len(v.strip()) == 0: # Pleroma bug workaround: Empty string becomes start of epoch json_object[k] = datetime.datetime.fromtimestamp(0) else: -- cgit v1.2.3