Skip to content

Commit 9e0b60f

Browse files
authored
Merge pull request #2221 from python-gitlab/jlvillal/unparse
chore: use `urlunparse` instead of string replace
2 parents d263f57 + 6d1b62d commit 9e0b60f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

gitlab/client.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -685,7 +685,7 @@ def http_request(
685685
params = parse.parse_qs(parsed.query)
686686
utils.copy_dict(src=query_data, dest=params)
687687

688-
url = raw_url.replace(parsed.query, "").strip("?")
688+
url = parse.urlunparse(parsed._replace(query=""))
689689

690690
# Deal with kwargs: by default a user uses kwargs to send data to the
691691
# gitlab server, but this generates problems (python keyword conflicts

0 commit comments

Comments
 (0)