* Add testcase.
This commit is contained in:
@@ -601,7 +601,7 @@ class gitlabModel extends model
|
||||
* @access public
|
||||
* @return object
|
||||
*/
|
||||
public function apiGetGroups($gitlabID, $orderBy, $minRole = '')
|
||||
public function apiGetGroups($gitlabID, $orderBy = 'id_desc', $minRole = '')
|
||||
{
|
||||
$apiRoot = $this->getApiRoot($gitlabID);
|
||||
$url = sprintf($apiRoot, "/groups");
|
||||
@@ -614,7 +614,9 @@ class gitlabModel extends model
|
||||
$url .= "&min_access_level=$this->config->gitlab->accessLevel[$minRole]";
|
||||
}
|
||||
|
||||
list($order, $sort) = explode('_', $orderBy);
|
||||
$order = 'id';
|
||||
$sort = 'desc';
|
||||
if(strpos($orderBy, '_') !== false) list($order, $sort) = explode('_', $orderBy);
|
||||
|
||||
$allResults = array();
|
||||
for($page = 1; true; $page++)
|
||||
|
||||
Reference in New Issue
Block a user