1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-18 04:42:40 +01:00

Fix a few issues with the "import symbols" script

Summary: Ref T7977. Fix a few issues that I forgot to fix up.

Test Plan: Run the script.

Reviewers: #blessed_reviewers, epriestley

Reviewed By: #blessed_reviewers, epriestley

Subscribers: Korvin, epriestley

Maniphest Tasks: T7977

Differential Revision: https://secure.phabricator.com/D12668
This commit is contained in:
Joshua Spence 2015-05-04 12:22:11 +10:00
parent 81d051dbfa
commit 1dfe1f49f7

View file

@ -35,20 +35,21 @@ $args->parse(
'be part of a single transaction.'), 'be part of a single transaction.'),
), ),
array( array(
'name' => 'more', 'name' => 'callsign',
'wildcard' => true, 'wildcard' => true,
), ),
)); ));
$more = $args->getArg('more'); $callsigns = $args->getArg('callsign');
if (count($more) !== 1) { if (count($callsigns) !== 1) {
$args->printHelpAndExit(); $args->printHelpAndExit();
} }
$callsign = head($more); $callsign = head($callsigns);
$repository = id(new PhabricatorRepository())->loadOneWhere( $repository = id(new PhabricatorRepositoryQuery())
'callsign = %s', ->setViewer(PhabricatorUser::getOmnipotentUser())
$callsign); ->withCallsigns($callsigns)
->executeOne();
if (!$repository) { if (!$repository) {
echo pht("Repository '%s' does not exist.", $callsign); echo pht("Repository '%s' does not exist.", $callsign);