1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-15 11:22:40 +01:00
phorge-phorge/src/applications/maniphest/engineextension/ManiphestProjectNameFulltextEngineExtension.php

26 lines
566 B
PHP
Raw Normal View History

<?php
final class ManiphestProjectNameFulltextEngineExtension
extends PhabricatorFulltextEngineExtension {
const EXTENSIONKEY = 'maniphest.project.name';
public function getExtensionName() {
return pht('Maniphest Project Name Cache');
}
public function shouldIndexFulltextObject($object) {
return ($object instanceof PhabricatorProject);
}
public function indexFulltextObject(
$object,
PhabricatorSearchAbstractDocument $document) {
ManiphestNameIndex::updateIndex(
$object->getPHID(),
$object->getName());
}
}