has_key is deprecated.

This commit is contained in:
Christophe Boulanger 2019-12-04 11:04:16 +01:00
parent 1a679611c2
commit 8f2b714580
1 changed files with 1 additions and 1 deletions

View File

@ -88,7 +88,7 @@ class ImioLiegeLisrue(BaseResource):
result = requests.get(
url, headers={"Accept": "application/json"}, verify=self.verify_cert
).json()
if result.has_key("data"):
if "data" in result:
result["rues"] = result.pop("data")
if isinstance(result["rues"], list):
lisrues = result["rues"]