Skip to content

Commit ebe1dda

Browse files
dim0x69dsl-bdimi
authored
Add URL encoding for multiple GET parameters (#645)
* Fix Bug in rest_client: Add & if params already in URL * Fix the fix :) * Update to #645 * Fix black formatting Co-authored-by: Slamaris Dimitrios (Bosch PSIRT) <[email protected]> Co-authored-by: dimi <[email protected]>
1 parent 488933f commit ebe1dda

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

atlassian/rest_client.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -195,8 +195,11 @@ def request(
195195
"""
196196
url = self.url_joiner(None if absolute else self.url, path, trailing)
197197
params_already_in_url = True if "?" in url else False
198-
if (params or flags) and not params_already_in_url:
199-
url += "?"
198+
if params or flags:
199+
if params_already_in_url:
200+
url += "&"
201+
else:
202+
url += "?"
200203
if params:
201204
url += urlencode(params or {})
202205
if flags:

0 commit comments

Comments
 (0)