protected function applyCustomExternalTransaction(PhabricatorLiskDAO $object, PhabricatorApplicationTransaction $xaction)
 {
     switch ($xaction->getTransactionType()) {
         case PhabricatorRepositoryTransaction::TYPE_AUTOMATION_BLUEPRINTS:
             DrydockAuthorization::applyAuthorizationChanges($this->getActor(), $object->getPHID(), $xaction->getOldValue(), $xaction->getNewValue());
             break;
     }
 }
 protected function applyCustomExternalTransaction(PhabricatorLiskDAO $object, PhabricatorApplicationTransaction $xaction)
 {
     switch ($xaction->getTransactionType()) {
         case PhabricatorRepositoryTransaction::TYPE_CREDENTIAL:
             // Adjust the object <-> credential edge for this repository.
             $old_phid = $xaction->getOldValue();
             $new_phid = $xaction->getNewValue();
             $editor = new PhabricatorEdgeEditor();
             $edge_type = PhabricatorObjectUsesCredentialsEdgeType::EDGECONST;
             $src_phid = $object->getPHID();
             if ($old_phid) {
                 $editor->removeEdge($src_phid, $edge_type, $old_phid);
             }
             if ($new_phid) {
                 $editor->addEdge($src_phid, $edge_type, $new_phid);
             }
             $editor->save();
             break;
         case PhabricatorRepositoryTransaction::TYPE_AUTOMATION_BLUEPRINTS:
             DrydockAuthorization::applyAuthorizationChanges($this->getActor(), $object->getPHID(), $xaction->getOldValue(), $xaction->getNewValue());
             break;
     }
 }
 public function applyApplicationTransactionExternalEffects(PhabricatorApplicationTransaction $xaction)
 {
     $old = $this->decodeValue($xaction->getOldValue());
     $new = $this->decodeValue($xaction->getNewValue());
     DrydockAuthorization::applyAuthorizationChanges($this->getViewer(), $xaction->getObjectPHID(), $old, $new);
 }