Skip to content

Commit 8f1454d

Browse files
authored
Update Projects.php
use the OptionResolver
1 parent c68e564 commit 8f1454d

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

lib/Gitlab/Api/Projects.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -504,7 +504,12 @@ public function removeLabel($project_id, $name)
504504
*/
505505
public function fork($project_id, array $params = array())
506506
{
507-
return $this->post($this->getProjectPath($project_id, 'fork'), $params);
507+
$resolver = $this->createOptionsResolver();
508+
$resolver->setDefined('namespace');
509+
510+
$resolved = $resolver->resolve($params);
511+
512+
return $this->post($this->getProjectPath($project_id, 'fork'), $resolved);
508513
}
509514

510515
/**

0 commit comments

Comments
 (0)