1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-15 19:32:40 +01:00
phorge-phorge/src/applications/diffusion/remarkup/DiffusionRepositoryByIDRemarkupRule.php

30 lines
572 B
PHP
Raw Normal View History

<?php
final class DiffusionRepositoryByIDRemarkupRule
extends PhabricatorObjectRemarkupRule {
protected function getObjectNamePrefix() {
return 'R';
}
protected function getObjectIDPattern() {
return '[0-9]+';
}
public function getPriority() {
return 460.0;
}
protected function loadObjects(array $ids) {
$viewer = $this->getEngine()->getConfig('viewer');
$repos = id(new PhabricatorRepositoryQuery())
->setViewer($viewer)
->withIdentifiers($ids);
$repos->execute();
return $repos->getIdentifierMap();
}
}