diff --git a/module/git/model.php b/module/git/model.php index 38c9ced53f..fd53ee1389 100644 --- a/module/git/model.php +++ b/module/git/model.php @@ -95,7 +95,11 @@ class gitModel extends model $lastInDB = $this->repo->getLatestCommit($repoID); /* Ignore unsynced branch. */ - if(empty($lastInDB)) continue; + if(empty($lastInDB)) + { + $this->printLog("Please init repo {$repo->name}"); + continue; + } $commits = $repo->commits; $version = $lastInDB->commit; diff --git a/module/svn/model.php b/module/svn/model.php index 6ec9e7cadb..7e53589ae2 100644 --- a/module/svn/model.php +++ b/module/svn/model.php @@ -89,7 +89,11 @@ class svnModel extends model $this->printLog("get this repo logs."); $lastInDB = $this->repo->getLatestCommit($repoID); /* Ignore unsynced repo. */ - if(empty($lastInDB)) continue; + if(empty($lastInDB)) + { + $this->printLog("Please init repo {$repo->name}"); + continue; + } $version = $lastInDB->commit; $logs = $this->repo->getUnsyncCommits($repo);