Skip to content

Commit 27275fe

Browse files
authored
fix missing error msg (#1378)
1 parent 8f7e4e3 commit 27275fe

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

atlassian/rest_client.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -537,7 +537,9 @@ def raise_for_status(self, response):
537537
else:
538538
error_msg_list = j.get("errorMessages", list())
539539
errors = j.get("errors", dict())
540-
if isinstance(errors, dict):
540+
if isinstance(errors, dict) and "message" not in errors:
541+
error_msg_list.extend(errors.values())
542+
elif isinstance(errors, dict) and "message" in errors:
541543
error_msg_list.append(errors.get("message", ""))
542544
elif isinstance(errors, list):
543545
error_msg_list.extend([v.get("message", "") if isinstance(v, dict) else v for v in errors])

0 commit comments

Comments
 (0)