Skip to content

Commit be5cd8e

Browse files
Hani YacoubHani Yacoub
authored andcommitted
changes on decode function
1 parent 50755a1 commit be5cd8e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

modules/util.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,8 @@ def decode_url(self, driver: Firefox):
308308
"""Decode to base64"""
309309
base64_data = driver.current_url.split(",")[1]
310310
decoded_data = base64.b64decode(base64_data).decode("utf-8")
311-
json_data = json.loads(decoded_data)
311+
normalized_str = decoded_data.replace('\r\n', '\n')
312+
json_data = json.loads(normalized_str)
312313
return json_data
313314

314315
def assert_json_value(self, json_data, jsonpath_expr, expected_value):

0 commit comments

Comments
 (0)