Revert "Revert "Merge branch 'devops18_caoyanyi' into 'master'""

This reverts commit 3a0ec82016.
This commit is contained in:
Hao Sun
2021-12-31 17:35:39 +08:00
parent 3a0ec82016
commit a9cc771d85
2 changed files with 11 additions and 8 deletions
+2 -1
View File
@@ -2539,7 +2539,8 @@ class gitlabModel extends model
*/
public function apiCreateBranchPriv($gitlabID, $projectID, $priv)
{
if(empty($gitlabID)) return false;
if(empty($gitlabID)) return false;
if(empty($projectID)) return false;
if(empty($priv->name)) return false;
$url = sprintf($this->getApiRoot($gitlabID), "/projects/" . $projectID . '/protected_branches');
return json_decode(commonModel::http($url, $priv));