@@ -109,21 +109,27 @@ public function show($project_id, $mr_id)
109
109
* @param string $source
110
110
* @param string $target
111
111
* @param string $title
112
- * @param int $assignee
113
- * @param int $target_project_id
114
- * @param string $description
112
+ * @param int $assignee @deprecated will be moved into $optionalParams
113
+ * @param int $target_project_id @deprecated will be moved into $optionalParams
114
+ * @param string $description @deprecated will be moved into $optionalParams
115
+ * @param array $optionalParams
115
116
* @return mixed
116
117
*/
117
- public function create ($ project_id , $ source , $ target , $ title , $ assignee = null , $ target_project_id = null , $ description = null )
118
+ public function create ($ project_id , $ source , $ target , $ title , $ assignee = null , $ target_project_id = null , $ description = null , array $ optionalParams = [] )
118
119
{
119
- return $ this -> post ( $ this -> getProjectPath ( $ project_id , ' merge_requests ' ), array (
120
+ $ baseParams = [
120
121
'source_branch ' => $ source ,
121
122
'target_branch ' => $ target ,
122
123
'title ' => $ title ,
123
124
'assignee_id ' => $ assignee ,
125
+ 'description ' => $ description ,
124
126
'target_project_id ' => $ target_project_id ,
125
- 'description ' => $ description
126
- ));
127
+ ];
128
+
129
+ return $ this ->post (
130
+ $ this ->getProjectPath ($ project_id , 'merge_requests ' ),
131
+ array_merge ($ baseParams , $ optionalParams )
132
+ );
127
133
}
128
134
129
135
/**
0 commit comments