mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-30 02:32:42 +01:00
Fix some odd looking arrays
Summary: These arrays looks a little odd, most likely due to the autofix applied by `ArcanistXHPASTLinter::LINT_ARRAY_SEPARATOR`. See D12296 in which I attempt to improve the autocorrection from this linter rule. Test Plan: N/A Reviewers: epriestley, #blessed_reviewers Reviewed By: epriestley, #blessed_reviewers Subscribers: epriestley Differential Revision: https://secure.phabricator.com/D12281
This commit is contained in:
parent
5b1d0f9ed7
commit
ea376685ae
31 changed files with 95 additions and 50 deletions
|
@ -6,7 +6,8 @@ $conn_w = $table->establishConnection('w');
|
|||
echo "Converting Maniphest project transactions to modern EDGE ".
|
||||
"transactions...\n";
|
||||
$metadata = array(
|
||||
'edge:type' => PhabricatorProjectObjectHasProjectEdgeType::EDGECONST,);
|
||||
'edge:type' => PhabricatorProjectObjectHasProjectEdgeType::EDGECONST,
|
||||
);
|
||||
foreach (new LiskMigrationIterator($table) as $txn) {
|
||||
// ManiphestTransaction::TYPE_PROJECTS
|
||||
if ($txn->getTransactionType() == 'projects') {
|
||||
|
|
|
@ -18,7 +18,8 @@ final class PhabricatorAuthManagementTrustOAuthClientWorkflow
|
|||
'name' => 'id',
|
||||
'param' => 'id',
|
||||
'help' => pht('The id of the OAuth client.'),
|
||||
),));
|
||||
),
|
||||
));
|
||||
}
|
||||
|
||||
public function execute(PhutilArgumentParser $args) {
|
||||
|
|
|
@ -18,7 +18,8 @@ final class PhabricatorAuthManagementUntrustOAuthClientWorkflow
|
|||
'name' => 'id',
|
||||
'param' => 'id',
|
||||
'help' => pht('The id of the OAuth client.'),
|
||||
),));
|
||||
),
|
||||
));
|
||||
}
|
||||
|
||||
public function execute(PhutilArgumentParser $args) {
|
||||
|
|
|
@ -256,7 +256,8 @@ abstract class PhabricatorController extends AphrontController {
|
|||
if ($must_sign_docs) {
|
||||
$controller = new LegalpadDocumentSignController();
|
||||
$this->getRequest()->setURIMap(array(
|
||||
'id' => head($must_sign_docs)->getID(),));
|
||||
'id' => head($must_sign_docs)->getID(),
|
||||
));
|
||||
$this->setCurrentApplication($legalpad);
|
||||
return $this->delegateToController($controller);
|
||||
} else {
|
||||
|
|
|
@ -283,7 +283,8 @@ final class PhabricatorConduitAPIController
|
|||
pht(
|
||||
'This request originates from outside of the Phabricator '.
|
||||
'cluster address range. Requests signed with trusted '.
|
||||
'device keys must originate from within the cluster.'),);
|
||||
'device keys must originate from within the cluster.'),
|
||||
);
|
||||
}
|
||||
|
||||
$user = PhabricatorUser::getOmnipotentUser();
|
||||
|
@ -384,7 +385,8 @@ final class PhabricatorConduitAPIController
|
|||
pht(
|
||||
'This request originates from outside of the Phabricator '.
|
||||
'cluster address range. Requests signed with cluster API '.
|
||||
'tokens must originate from within the cluster.'),);
|
||||
'tokens must originate from within the cluster.'),
|
||||
);
|
||||
}
|
||||
|
||||
// Flag this as an intracluster request.
|
||||
|
|
|
@ -107,20 +107,25 @@ final class PhabricatorBinariesSetupCheck extends PhabricatorSetupCheck {
|
|||
case PhabricatorRepositoryType::REPOSITORY_TYPE_SVN:
|
||||
$minimum_version = '1.5';
|
||||
$bad_versions = array(
|
||||
'1.7.1' => pht('This version of Subversion has a bug where '.
|
||||
'"svn diff -c N" does not work for files added '.
|
||||
'in rN (Subversion issue #2873), fixed in 1.7.2.'),);
|
||||
'1.7.1' => pht(
|
||||
'This version of Subversion has a bug where `%s` does not work '.
|
||||
'for files added in rN (Subversion issue #2873), fixed in 1.7.2.',
|
||||
'svn diff -c N'),
|
||||
);
|
||||
list($err, $stdout, $stderr) = exec_manual('svn --version --quiet');
|
||||
$version = trim($stdout);
|
||||
break;
|
||||
case PhabricatorRepositoryType::REPOSITORY_TYPE_MERCURIAL:
|
||||
$minimum_version = '1.9';
|
||||
$bad_versions = array(
|
||||
'2.1' => pht('This version of Mercurial returns a bad exit code '.
|
||||
'after a successful pull.'),
|
||||
'2.2' => pht('This version of Mercurial has a significant memory '.
|
||||
'leak, fixed in 2.2.1. Pushing fails with this '.
|
||||
'version as well; see T3046#54922.'),);
|
||||
'2.1' => pht(
|
||||
'This version of Mercurial returns a bad exit code '.
|
||||
'after a successful pull.'),
|
||||
'2.2' => pht(
|
||||
'This version of Mercurial has a significant memory leak, fixed '.
|
||||
'in 2.2.1. Pushing fails with this version as well; see %s.',
|
||||
'T3046#54922'),
|
||||
);
|
||||
$version = PhabricatorRepositoryVersion::getMercurialVersion();
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -9,7 +9,8 @@ abstract class ConpherenceTestCase extends PhabricatorTestCase {
|
|||
|
||||
$xactions = array(id(new ConpherenceTransaction())
|
||||
->setTransactionType(ConpherenceTransactionType::TYPE_PARTICIPANTS)
|
||||
->setNewValue(array('+' => $participant_phids)),);
|
||||
->setNewValue(array('+' => $participant_phids)),
|
||||
);
|
||||
$editor = id(new ConpherenceEditor())
|
||||
->setActor($actor)
|
||||
->setContentSource(PhabricatorContentSource::newConsoleSource())
|
||||
|
@ -24,7 +25,8 @@ abstract class ConpherenceTestCase extends PhabricatorTestCase {
|
|||
|
||||
$xactions = array(id(new ConpherenceTransaction())
|
||||
->setTransactionType(ConpherenceTransactionType::TYPE_PARTICIPANTS)
|
||||
->setNewValue(array('-' => $participant_phids)),);
|
||||
->setNewValue(array('-' => $participant_phids)),
|
||||
);
|
||||
$editor = id(new ConpherenceEditor())
|
||||
->setActor($actor)
|
||||
->setContentSource(PhabricatorContentSource::newConsoleSource())
|
||||
|
|
|
@ -125,7 +125,8 @@ final class ConpherenceListController extends ConpherenceController {
|
|||
->execute();
|
||||
|
||||
return array(
|
||||
'all_participation' => $all_participation,);
|
||||
'all_participation' => $all_participation,
|
||||
);
|
||||
}
|
||||
|
||||
private function loadConpherenceThreadData($participation) {
|
||||
|
|
|
@ -178,7 +178,8 @@ final class ConpherenceThreadSearchEngine
|
|||
return array(
|
||||
'rooms' => pht('Rooms'),
|
||||
'messages' => pht('Messages'),
|
||||
'both' => pht('Both'),);
|
||||
'both' => pht('Both'),
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -60,7 +60,8 @@ final class ConpherenceThread extends ConpherenceDAO
|
|||
),
|
||||
self::CONFIG_KEY_SCHEMA => array(
|
||||
'key_room' => array(
|
||||
'columns' => array('isRoom', 'dateModified'),),
|
||||
'columns' => array('isRoom', 'dateModified'),
|
||||
),
|
||||
'key_phid' => null,
|
||||
'phid' => array(
|
||||
'columns' => array('phid'),
|
||||
|
|
|
@ -375,8 +375,8 @@ final class ConpherenceDurableColumnView extends AphrontTagView {
|
|||
),
|
||||
$header),
|
||||
$settings_button,
|
||||
$settings_menu,));
|
||||
|
||||
$settings_menu,
|
||||
));
|
||||
}
|
||||
|
||||
private function getHeaderActionsConfig(ConpherenceThread $conpherence) {
|
||||
|
@ -418,7 +418,8 @@ final class ConpherenceDurableColumnView extends AphrontTagView {
|
|||
'href' => '#',
|
||||
'icon' => 'fa-times',
|
||||
'key' => 'hide_column',
|
||||
),);
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
private function buildTransactions() {
|
||||
|
@ -441,7 +442,8 @@ final class ConpherenceDurableColumnView extends AphrontTagView {
|
|||
'class' => 'button grey',
|
||||
'sigil' => 'workflow',
|
||||
),
|
||||
pht('Send a Message')),);
|
||||
pht('Send a Message')),
|
||||
);
|
||||
}
|
||||
|
||||
$data = ConpherenceTransactionView::renderTransactions(
|
||||
|
@ -501,7 +503,8 @@ final class ConpherenceDurableColumnView extends AphrontTagView {
|
|||
'type' => 'hidden',
|
||||
'name' => 'action',
|
||||
'value' => ConpherenceUpdateActions::MESSAGE,
|
||||
)),));
|
||||
)),
|
||||
));
|
||||
}
|
||||
|
||||
private function buildStatusText() {
|
||||
|
|
|
@ -179,7 +179,8 @@ EOTEXT
|
|||
phutil_tag(
|
||||
'a',
|
||||
array(
|
||||
'href' => $this->getInboundEmailSupportLink(),),
|
||||
'href' => $this->getInboundEmailSupportLink(),
|
||||
),
|
||||
pht('Learn More')));
|
||||
}
|
||||
|
||||
|
|
|
@ -163,11 +163,13 @@ final class DifferentialCreateDiffConduitAPIMethod
|
|||
$request->getValue('sourceControlBaseRevision'),
|
||||
'arcanistProjectPHID' => $project_phid,
|
||||
'lintStatus' => $lint_status,
|
||||
'unitStatus' => $unit_status,);
|
||||
'unitStatus' => $unit_status,
|
||||
);
|
||||
|
||||
$xactions = array(id(new DifferentialTransaction())
|
||||
->setTransactionType(DifferentialDiffTransaction::TYPE_DIFF_CREATE)
|
||||
->setNewValue($diff_data_dict),);
|
||||
->setNewValue($diff_data_dict),
|
||||
);
|
||||
|
||||
id(new DifferentialDiffEditor())
|
||||
->setActor($viewer)
|
||||
|
|
|
@ -53,11 +53,13 @@ final class DifferentialCreateRawDiffConduitAPIMethod
|
|||
'authorPHID' => $viewer->getPHID(),
|
||||
'repositoryPHID' => $repository_phid,
|
||||
'lintStatus' => DifferentialLintStatus::LINT_SKIP,
|
||||
'unitStatus' => DifferentialUnitStatus::UNIT_SKIP,);
|
||||
'unitStatus' => DifferentialUnitStatus::UNIT_SKIP,
|
||||
);
|
||||
|
||||
$xactions = array(id(new DifferentialTransaction())
|
||||
->setTransactionType(DifferentialDiffTransaction::TYPE_DIFF_CREATE)
|
||||
->setNewValue($diff_data_dict),);
|
||||
->setNewValue($diff_data_dict),
|
||||
);
|
||||
|
||||
if ($request->getValue('viewPolicy')) {
|
||||
$xactions[] = id(new DifferentialTransaction())
|
||||
|
|
|
@ -62,7 +62,8 @@ final class DifferentialRevisionCloseDetailsController
|
|||
phutil_tag(
|
||||
'a',
|
||||
array(
|
||||
'href' => $obj_handle->getURI(),),
|
||||
'href' => $obj_handle->getURI(),
|
||||
),
|
||||
$obj_handle->getName()));
|
||||
} else if ($revision_match_data['foundURI']) {
|
||||
$body_why[] = pht(
|
||||
|
@ -96,7 +97,8 @@ final class DifferentialRevisionCloseDetailsController
|
|||
$diff_link = phutil_tag(
|
||||
'a',
|
||||
array(
|
||||
'href' => $obj_handle->getURI(),),
|
||||
'href' => $obj_handle->getURI(),
|
||||
),
|
||||
$obj_handle->getName());
|
||||
$body_why = pht(
|
||||
'This commit and the active diff of %s had the same %s hash '.
|
||||
|
|
|
@ -59,7 +59,8 @@ final class DifferentialCreateMailReceiver extends PhabricatorMailReceiver {
|
|||
$call = new ConduitCall(
|
||||
'differential.createrawdiff',
|
||||
array(
|
||||
'diff' => $body,));
|
||||
'diff' => $body,
|
||||
));
|
||||
$call->setUser($sender);
|
||||
try {
|
||||
$result = $call->execute();
|
||||
|
|
|
@ -51,7 +51,8 @@ final class PhabricatorFilesApplication extends PhabricatorApplication {
|
|||
phutil_tag(
|
||||
'a',
|
||||
array(
|
||||
'href' => $this->getInboundEmailSupportLink(),),
|
||||
'href' => $this->getInboundEmailSupportLink(),
|
||||
),
|
||||
pht('Learn More')));
|
||||
}
|
||||
|
||||
|
|
|
@ -122,7 +122,8 @@ final class PhabricatorManiphestApplication extends PhabricatorApplication {
|
|||
phutil_tag(
|
||||
'a',
|
||||
array(
|
||||
'href' => $this->getInboundEmailSupportLink(),),
|
||||
'href' => $this->getInboundEmailSupportLink(),
|
||||
),
|
||||
pht('Learn More')));
|
||||
}
|
||||
|
||||
|
|
|
@ -55,7 +55,8 @@ final class PhabricatorPasteApplication extends PhabricatorApplication {
|
|||
phutil_tag(
|
||||
'a',
|
||||
array(
|
||||
'href' => $this->getInboundEmailSupportLink(),),
|
||||
'href' => $this->getInboundEmailSupportLink(),
|
||||
),
|
||||
pht('Learn More')));
|
||||
}
|
||||
|
||||
|
|
|
@ -376,7 +376,8 @@ final class PhrictionDocumentController
|
|||
$child_dict = array(
|
||||
'slug' => $child->getSlug(),
|
||||
'depth' => $child->getDepth(),
|
||||
'title' => $child->getContent()->getTitle(),);
|
||||
'title' => $child->getContent()->getTitle(),
|
||||
);
|
||||
if ($child->getDepth() == $d_child) {
|
||||
$children_dicts[] = $child_dict;
|
||||
continue;
|
||||
|
|
|
@ -132,7 +132,8 @@ final class PhrictionTransactionEditor
|
|||
'id' => $document->getID(),
|
||||
'phid' => $document->getPHID(),
|
||||
'content' => $document->getContent()->getContent(),
|
||||
'title' => $document->getContent()->getTitle(),);
|
||||
'title' => $document->getContent()->getTitle(),
|
||||
);
|
||||
return $dict;
|
||||
case PhrictionTransaction::TYPE_MOVE_AWAY:
|
||||
$document = $xaction->getNewValue();
|
||||
|
@ -140,7 +141,8 @@ final class PhrictionTransactionEditor
|
|||
'id' => $document->getID(),
|
||||
'phid' => $document->getPHID(),
|
||||
'content' => $document->getContent()->getContent(),
|
||||
'title' => $document->getContent()->getTitle(),);
|
||||
'title' => $document->getContent()->getTitle(),
|
||||
);
|
||||
return $dict;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -22,7 +22,8 @@ final class PhabricatorPolicyConfigOptions
|
|||
public function getOptions() {
|
||||
$policy_locked_type = 'custom:PolicyLockOptionType';
|
||||
$policy_locked_example = array(
|
||||
'people.create.users' => 'admin',);
|
||||
'people.create.users' => 'admin',
|
||||
);
|
||||
$json = new PhutilJSON();
|
||||
$policy_locked_example = $json->encodeFormatted($policy_locked_example);
|
||||
|
||||
|
|
|
@ -49,7 +49,8 @@ final class PhabricatorApplicationTransactionShowOlderController
|
|||
|
||||
return id(new AphrontAjaxResponse())
|
||||
->setContent(array(
|
||||
'timeline' => hsprintf('%s', $events),));
|
||||
'timeline' => hsprintf('%s', $events),
|
||||
));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -39,7 +39,8 @@ final class PhabricatorInlineSummaryView extends AphrontView {
|
|||
),
|
||||
array(
|
||||
$icon,
|
||||
$group,));
|
||||
$group,
|
||||
));
|
||||
$rows[] = phutil_tag('tr', array(), $header);
|
||||
|
||||
foreach ($items as $item) {
|
||||
|
|
|
@ -305,7 +305,8 @@ final class AphrontTableView extends AphrontView {
|
|||
$html = phutil_tag(
|
||||
'table',
|
||||
array(
|
||||
'class' => implode(' ', $classes),),
|
||||
'class' => implode(' ', $classes),
|
||||
),
|
||||
$table);
|
||||
return phutil_tag_div('aphront-table-wrap', $html);
|
||||
}
|
||||
|
|
|
@ -212,7 +212,8 @@ abstract class AphrontFormControl extends AphrontView {
|
|||
),
|
||||
array(
|
||||
$this->getLabel(),
|
||||
$error,));
|
||||
$error,
|
||||
));
|
||||
} else {
|
||||
$label = null;
|
||||
$custom_class .= ' aphront-form-control-nolabel';
|
||||
|
|
|
@ -81,7 +81,8 @@ final class PhabricatorTransactionView extends AphrontView {
|
|||
array(
|
||||
$image,
|
||||
phutil_tag_div('phabricator-transaction-detail grouped',
|
||||
array($header, $content)),));
|
||||
array($header, $content)),
|
||||
));
|
||||
|
||||
}
|
||||
|
||||
|
@ -129,7 +130,8 @@ final class PhabricatorTransactionView extends AphrontView {
|
|||
return phutil_tag(
|
||||
'span',
|
||||
array(
|
||||
'class' => 'phabricator-transaction-info',),
|
||||
'class' => 'phabricator-transaction-info',
|
||||
),
|
||||
$info);
|
||||
}
|
||||
|
||||
|
|
|
@ -174,7 +174,8 @@ final class PHUIDocumentView extends AphrontTagView {
|
|||
'map' => array(
|
||||
$this->actionListID => 'phabricator-action-list-toggle',
|
||||
$icon_id => 'phuix-dropdown-open',
|
||||
),);
|
||||
),
|
||||
);
|
||||
$mobile_menu = id(new PHUIButtonView())
|
||||
->setTag('a')
|
||||
->setText(pht('Actions'))
|
||||
|
|
|
@ -171,7 +171,8 @@ final class PHUIObjectBoxView extends AphrontView {
|
|||
'map' => array(
|
||||
$this->actionListID => 'phabricator-action-list-toggle',
|
||||
$icon_id => 'phuix-dropdown-open',
|
||||
),);
|
||||
),
|
||||
);
|
||||
$mobile_menu = id(new PHUIButtonView())
|
||||
->setTag('a')
|
||||
->setText(pht('Actions'))
|
||||
|
|
|
@ -581,7 +581,8 @@ final class PHUIObjectItemView extends AphrontTagView {
|
|||
),
|
||||
array(
|
||||
$icons,
|
||||
$bylines,));
|
||||
$bylines,
|
||||
));
|
||||
}
|
||||
|
||||
$table = phutil_tag(
|
||||
|
|
|
@ -435,7 +435,8 @@ final class PHUITimelineEventView extends AphrontView {
|
|||
'class' => 'phui-timeline-event-view '.
|
||||
'phui-timeline-spacer '.
|
||||
'phui-timeline-spacer-bold',
|
||||
'',));
|
||||
'',
|
||||
));
|
||||
}
|
||||
|
||||
return array(
|
||||
|
@ -453,7 +454,8 @@ final class PHUITimelineEventView extends AphrontView {
|
|||
'class' => implode(' ', $classes),
|
||||
),
|
||||
$content)),
|
||||
$major_event,);
|
||||
$major_event,
|
||||
);
|
||||
}
|
||||
|
||||
private function renderExtra(array $events) {
|
||||
|
|
Loading…
Reference in a new issue