mirror of
https://we.phorge.it/source/phorge.git
synced 2025-02-16 16:58:38 +01:00
26 lines
526 B
PHP
26 lines
526 B
PHP
|
<?php
|
||
|
|
||
|
final class DiffusionRepositoryRemarkupRule
|
||
|
extends PhabricatorRemarkupRuleObject {
|
||
|
|
||
|
protected function getObjectNamePrefix() {
|
||
|
return 'r';
|
||
|
}
|
||
|
|
||
|
protected function getObjectIDPattern() {
|
||
|
return '[A-Z]+';
|
||
|
}
|
||
|
|
||
|
protected function loadObjects(array $ids) {
|
||
|
$viewer = $this->getEngine()->getConfig('viewer');
|
||
|
|
||
|
$repositories = id(new PhabricatorRepositoryQuery())
|
||
|
->setViewer($viewer)
|
||
|
->withCallsigns($ids)
|
||
|
->execute();
|
||
|
|
||
|
return mpull($repositories, null, 'getCallsign');
|
||
|
}
|
||
|
|
||
|
}
|