summaryrefslogtreecommitdiff
path: root/gitlab.py
diff options
context:
space:
mode:
authorGauvain Pocentek <gauvain@pocentek.net>2014-10-11 08:50:38 +0200
committerGauvain Pocentek <gauvain@pocentek.net>2014-10-11 08:50:38 +0200
commit4664ebd9125d4eb07ee2add768b89362c6902f81 (patch)
tree27128b031711a2cdf9411b05fb7cc60f1e60b9fe /gitlab.py
parent2c860856689bac90bbda44d4812a27d5b22144c0 (diff)
parentafcf1c23c36a7aa0f65392892ca4abb973e35b43 (diff)
downloadgitlab-4664ebd9125d4eb07ee2add768b89362c6902f81.tar.gz
Merge pull request #38 from mjmaenpaa/currentuser_key
Changed CurrentUser.Key to use _getListOrObject-method like all other functions
Diffstat (limited to 'gitlab.py')
-rw-r--r--gitlab.py6
1 files changed, 1 insertions, 5 deletions
diff --git a/gitlab.py b/gitlab.py
index 34da77d..268fe5c 100644
--- a/gitlab.py
+++ b/gitlab.py
@@ -667,11 +667,7 @@ class CurrentUser(GitlabObject):
shortPrintAttr = 'username'
def Key(self, id=None, **kwargs):
- if id is None:
- return CurrentUserKey.list(self.gitlab, **kwargs)
- else:
- return CurrentUserKey(self.gitlab, id)
-
+ return self._getListOrObject(CurrentUserKey, id, **kwargs)
class GroupMember(GitlabObject):
_url = '/groups/%(group_id)s/members'