Removed deprecated encoding argument in json.loads

This commit is contained in:
Manuel Cortez 2022-01-05 17:39:11 -06:00
parent 855e7efa8a
commit 17b9161813
No known key found for this signature in database
GPG Key ID: 9E0735CA15EFE790
2 changed files with 2 additions and 2 deletions

View File

@ -22,7 +22,7 @@ class client(object):
self.disconnected(event.peer)
elif event.type == enet.EVENT_TYPE_RECEIVE:
data = event.packet.data
data_dict = json.loads(data, encoding="utf-8")
data_dict = json.loads(data)
self.network(event, data_dict)
time.sleep(0.001)

View File

@ -45,7 +45,7 @@ class server(object):
print("Error receiving packet for invalid channel: %r" % (event.data))
return
data = event.packet.data
data_dict = json.loads(data, encoding="utf-8")
data_dict = json.loads(data)
channel_object.network(event, data_dict)
time.sleep(0.0001)