1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-24 06:20:56 +01:00

Minor linter fixes

Summary: Fix a few minor lint issues.

Test Plan: Ran `arc lint`.

Reviewers: #blessed_reviewers, epriestley

Subscribers: Korvin, epriestley

Differential Revision: https://secure.phabricator.com/D11059
This commit is contained in:
Joshua Spence 2014-12-30 02:48:03 -08:00 committed by epriestley
parent 9374ace602
commit eedd7aa58b
5 changed files with 13 additions and 5 deletions

View file

@ -1331,8 +1331,9 @@ final class DifferentialTransactionEditor
$previous_comments = $comments_by_line_number[$comment->getChangesetID()]
[$comment->getLineNumber()];
foreach ($previous_comments as $previous_comment) {
if ($previous_comment->getID() >= $comment->getID())
if ($previous_comment->getID() >= $comment->getID()) {
break;
}
$nested = $this->indentForMail(
array_merge(
$nested,

View file

@ -43,8 +43,9 @@ final class DifferentialLandingActionMenuEventListener
foreach ($strategies as $strategy) {
$viewer = $event->getUser();
$action = $strategy->createMenuItem($viewer, $revision, $repository);
if ($action == null)
if ($action == null) {
continue;
}
if ($strategy->isActionDisabled($viewer, $revision, $repository)) {
$action->setDisabled(true);
}

View file

@ -127,15 +127,18 @@ final class ReleephRequest extends ReleephDAO
if ($this->getInBranch()) {
return ReleephRequestStatus::STATUS_NEEDS_REVERT;
} else {
$intent_pass = ReleephRequest::INTENT_PASS;
$intent_want = ReleephRequest::INTENT_WANT;
$has_been_in_branch = $this->getCommitIdentifier();
// Regardless of why we reverted something, always say reverted if it
// was once in the branch.
if ($has_been_in_branch) {
return ReleephRequestStatus::STATUS_REVERTED;
} else if ($this->getPusherIntent() === ReleephRequest::INTENT_PASS) {
} else if ($this->getPusherIntent() === $intent_pass) {
// Otherwise, if it has never been in the branch, explicitly say why:
return ReleephRequestStatus::STATUS_REJECTED;
} else if ($this->getRequestorIntent() === ReleephRequest::INTENT_WANT) {
} else if ($this->getRequestorIntent() === $intent_want) {
return ReleephRequestStatus::STATUS_REQUESTED;
} else {
return ReleephRequestStatus::STATUS_ABANDONED;

View file

@ -52,6 +52,7 @@ final class PhabricatorRepositoryPullEngine
break;
default:
$this->abortPull(pht('Unknown VCS "%s"!', $vcs));
break;
}
$callsign = $repository->getCallsign();

View file

@ -43,7 +43,9 @@ final class PHUIInfoPanelView extends AphrontView {
$tds[] = $this->renderCell($cell);
unset($this->infoblock[$key]);
$ii++;
if ($ii > $this->columns) break;
if ($ii > $this->columns) {
break;
}
}
$trs[] = phutil_tag(
'tr',