diff options
author | Nejc Habjan <hab.nejc@gmail.com> | 2020-02-23 17:22:21 +0100 |
---|---|---|
committer | Nejc Habjan <hab.nejc@gmail.com> | 2020-02-23 17:23:09 +0100 |
commit | 2e396e4a84690c2ea2ea7035148b1a6038c03301 (patch) | |
tree | d350f4644b4c40caad5d91ec2e76410ee3828d7d /gitlab | |
parent | 32844c7b27351b08bb86d8f9bd8fe9cf83917a5a (diff) | |
download | gitlab-2e396e4a84690c2ea2ea7035148b1a6038c03301.tar.gz |
fix: remove trailing slashes from base URL (#913)
Diffstat (limited to 'gitlab')
-rw-r--r-- | gitlab/__init__.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gitlab/__init__.py b/gitlab/__init__.py index 9a3a8b1..32aa265 100644 --- a/gitlab/__init__.py +++ b/gitlab/__init__.py @@ -90,8 +90,8 @@ class Gitlab(object): self._api_version = str(api_version) self._server_version = self._server_revision = None - self._base_url = url - self._url = "%s/api/v%s" % (url, api_version) + self._base_url = url.rstrip("/") + self._url = "%s/api/v%s" % (self._base_url, api_version) #: Timeout to use for requests to gitlab server self.timeout = timeout #: Headers that will be used in request to GitLab |