Skip to content

Commit 2275e53

Browse files
committed
Fix several "extra action" function urls
Fixed Group.transfer_project(), SystemHook.test(), and MergeRequest.post_comment()
1 parent 9d594d3 commit 2275e53

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

gitlab3/_api_definition.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ def plural_name(cls):
4848

4949
class ExtraActionDefinition(object):
5050
"""Definition of a "non-standard" function"""
51-
url = None
51+
url = ''
5252
url_params = []
5353
required_params = []
5454
optional_params = []
@@ -84,7 +84,7 @@ class Group(APIDefinition):
8484

8585
class TransferProjectAction(ExtraActionDefinition):
8686
"""gl.Group.transfer_project(project_id)"""
87-
url = '/groups/:id/projects/:project_id'
87+
url = '/projects/:project_id'
8888
method = _HTTP_POST
8989
url_params = [
9090
'project_id',
@@ -101,7 +101,6 @@ class SystemHook(APIDefinition):
101101

102102
class TestAction(ExtraActionDefinition):
103103
"""gl.Hook.test()"""
104-
url = '/hooks/:id'
105104
method = _HTTP_GET
106105
extra_actions = [ TestAction ]
107106

@@ -307,7 +306,7 @@ class MergeRequest(APIDefinition):
307306

308307
class PostCommentAction(ExtraActionDefinition):
309308
"""gl.Project.MergeRequest.post_comment(note)"""
310-
url = '/merge_request/:merge_request_id/comments'
309+
url = '/comments'
311310
method = _HTTP_POST
312311
required_args = [
313312
'note',

0 commit comments

Comments
 (0)