From 515dd085c4d406621c7dc115d718596f7f1f9307 Mon Sep 17 00:00:00 2001 From: zenggang Date: Tue, 8 Mar 2022 09:40:28 +0000 Subject: [PATCH] * Adjust code --- lib/scm/gitlab.class.php | 2 +- module/repo/model.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/scm/gitlab.class.php b/lib/scm/gitlab.class.php index e5645e816c..861bffbd95 100644 --- a/lib/scm/gitlab.class.php +++ b/lib/scm/gitlab.class.php @@ -646,7 +646,7 @@ class gitlab $param = new stdclass(); $param->path = urldecode($path); - $param->ref_name = $fromRevision ? $fromRevision : $this->branch; + $param->ref_name = $toRevision ? $toRevision : $this->branch; $fromDate = $this->getCommittedDate($fromRevision); $toDate = $this->getCommittedDate($toRevision); diff --git a/module/repo/model.php b/module/repo/model.php index ab12ca3c29..2f13bb5f2e 100644 --- a/module/repo/model.php +++ b/module/repo/model.php @@ -882,7 +882,7 @@ class repoModel extends model $scm = $this->app->loadClass('scm'); $scm->setEngine($repo); - $logs = $scm->log('', $lastInDB ? $lastInDB->revision : 0); + $logs = $scm->log('', $lastInDB ? $lastInDB->revision : 0, ''); if(empty($logs)) return false; /* Process logs. */