Skip to content

Commit 62b4684

Browse files
coding46m1guelpf
authored andcommitted
Use OptionsResolver in Projects variables api
1 parent 9c5c2a3 commit 62b4684

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

lib/Gitlab/Api/Projects.php

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -556,11 +556,15 @@ public function removeService($project_id, $service_name)
556556

557557
/**
558558
* @param int $project_id
559+
* @param array $parameters
560+
*
559561
* @return mixed
560562
*/
561-
public function variables($project_id)
563+
public function variables($project_id, array $parameters = [])
562564
{
563-
return $this->get($this->getProjectPath($project_id, 'variables'));
565+
$resolver = $this->createOptionsResolver();
566+
567+
return $this->get($this->getProjectPath($project_id, 'variables'), $resolver->resolve($parameters));
564568
}
565569

566570
/**

0 commit comments

Comments
 (0)