Cosmetic improvements.
This commit is contained in:
@@ -35,19 +35,14 @@ class IDF_ScmFactory
|
||||
public static function getScm($request=null)
|
||||
{
|
||||
// Get scm type from project conf ; defaults to git
|
||||
$scm = $request->conf->getVal('scm', 'git');
|
||||
|
||||
// CASE: git
|
||||
if ($scm === 'git') {
|
||||
return new IDF_Git($request->project->getGitRepository());
|
||||
}
|
||||
|
||||
// CASE: svn
|
||||
if ($scm === 'svn') {
|
||||
switch ($request->conf->getVal('scm', 'git')) {
|
||||
case 'svn':
|
||||
return new IDF_Svn($request->conf->getVal('svn_repository'),
|
||||
$request->conf->getVal('svn_username'),
|
||||
$request->conf->getVal('svn_password'));
|
||||
}
|
||||
case 'git':
|
||||
default:
|
||||
return new IDF_Git($request->project->getGitRepository());
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user