1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2025-02-18 09:48:39 +01:00

Initialize variable in Next Step

Test Plan: None.

Reviewers: epriestley

Reviewed By: epriestley

CC: aran, Korvin

Differential Revision: https://secure.phabricator.com/D5020
This commit is contained in:
vrana 2013-02-19 15:25:27 -08:00
parent 2f66138464
commit ee663afdeb

View file

@ -71,27 +71,25 @@ final class DifferentialRevisionDetailView extends AphrontView {
switch ($local_vcs) { switch ($local_vcs) {
case PhabricatorRepositoryType::REPOSITORY_TYPE_MERCURIAL: case PhabricatorRepositoryType::REPOSITORY_TYPE_MERCURIAL:
$bookmark = $this->getDiff()->getBookmark(); $bookmark = $this->getDiff()->getBookmark();
$command = ($bookmark != '' $next_step = ($bookmark != ''
? csprintf('arc land %s', $bookmark) ? csprintf('arc land %s', $bookmark)
: 'arc land'); : 'arc land');
break; break;
case PhabricatorRepositoryType::REPOSITORY_TYPE_GIT: case PhabricatorRepositoryType::REPOSITORY_TYPE_GIT:
$branch = $this->getDiff()->getBranch(); $branch = $this->getDiff()->getBranch();
$command = ($branch != '' $next_step = ($branch != ''
? csprintf('arc land %s', $branch) ? csprintf('arc land %s', $branch)
: 'arc land'); : 'arc land');
break; break;
case PhabricatorRepositoryType::REPOSITORY_TYPE_SVN: case PhabricatorRepositoryType::REPOSITORY_TYPE_SVN:
$command = 'arc commit'; $next_step = 'arc commit';
break; break;
} }
if ($command) {
$next_step = phutil_tag('tt', array(), $command);
}
} }
if ($next_step) { if ($next_step) {
$next_step = phutil_tag('tt', array(), $next_step);
$properties->addProperty(pht('Next Step'), $next_step); $properties->addProperty(pht('Next Step'), $next_step);
} }