Commit b1370dc1 authored by Federico Sismondi's avatar Federico Sismondi

get api version from json when using Message.from_json(json) message builder

parent 7d1e46b3
......@@ -117,7 +117,8 @@ class Message:
self._msg_data.update(kwargs)
# add API's version
self._msg_data["_api_version"] = API_VERSION
if not "_api_version" in self._msg_data:
self._msg_data["_api_version"] = API_VERSION
# add values as objects attributes
for key in self._msg_data:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment