Fix error - message content

This commit is contained in:
Tomasz 2021-01-31 22:11:25 +01:00
parent f0d68faf09
commit e15a57cbfd

View file

@ -196,4 +196,10 @@ def get_message_content(register_id, register_r, oun, s, date, school_year, symb
content = sess.post(f'{link}/Wiadomosc.mvc/GetInboxMessageDetails', data=json.dumps(payload)) content = sess.post(f'{link}/Wiadomosc.mvc/GetInboxMessageDetails', data=json.dumps(payload))
if content.status_code != 200:
while True:
content = sess.post(f'{link}/Wiadomosc.mvc/GetInboxMessageDetails', data=json.dumps(payload))
if content.status_code == 200:
break
return content.json() return content.json()