fix NameError: name 'x' is not defined in __json_date_parse()

pull/278/head
adbenitez 2022-11-24 14:53:36 -05:00
rodzic 5d7ca19c30
commit 649b6cabe0
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -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: