1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-18 11:30:55 +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.'),
),
array(
'name' => 'more',
'name' => 'callsign',
'wildcard' => true,
),
));
$more = $args->getArg('more');
if (count($more) !== 1) {
$callsigns = $args->getArg('callsign');
if (count($callsigns) !== 1) {
$args->printHelpAndExit();
}
$callsign = head($more);
$repository = id(new PhabricatorRepository())->loadOneWhere(
'callsign = %s',
$callsign);
$callsign = head($callsigns);
$repository = id(new PhabricatorRepositoryQuery())
->setViewer(PhabricatorUser::getOmnipotentUser())
->withCallsigns($callsigns)
->executeOne();
if (!$repository) {
echo pht("Repository '%s' does not exist.", $callsign);