Skip to content

Commit 726e969

Browse files
authored
Updating user_get_websudo to set the not_json_response as true (#1272)
1 parent 364b16f commit 726e969

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

atlassian/jira.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1966,11 +1966,12 @@ def user_get_websudo(self):
19661966
"webSudoPassword": self.password,
19671967
"webSudoIsPost": "false",
19681968
}
1969-
answer = self.get("secure/admin/WebSudoAuthenticate.jspa", self.form_token_headers)
1969+
answer = self.get("secure/admin/WebSudoAuthenticate.jspa", self.form_token_headers, not_json_response=True)
1970+
decoded_answer = answer.decode()
19701971
atl_token = None
1971-
if answer:
1972+
if decoded_answer:
19721973
atl_token = (
1973-
answer.split('<meta id="atlassian-token" name="atlassian-token" content="')[1]
1974+
decoded_answer.split('<meta id="atlassian-token" name="atlassian-token" content="')[1]
19741975
.split("\n")[0]
19751976
.split('"')[0]
19761977
)

0 commit comments

Comments
 (0)