@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
at upstream/main 25 lines 533 B view raw
1<?php 2 3abstract class NuanceWorker extends PhabricatorWorker { 4 5 protected function getViewer() { 6 return PhabricatorUser::getOmnipotentUser(); 7 } 8 9 protected function loadItem($item_phid) { 10 $item = id(new NuanceItemQuery()) 11 ->setViewer($this->getViewer()) 12 ->withPHIDs(array($item_phid)) 13 ->executeOne(); 14 15 if (!$item) { 16 throw new PhabricatorWorkerPermanentFailureException( 17 pht( 18 'There is no Nuance item with PHID "%s".', 19 $item_phid)); 20 } 21 22 return $item; 23 } 24 25}