@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 39 lines 873 B view raw
1<?php 2 3final class PhabricatorAuthMessageTextTransaction 4 extends PhabricatorAuthMessageTransactionType { 5 6 const TRANSACTIONTYPE = 'text'; 7 8 public function generateOldValue($object) { 9 return $object->getMessageText(); 10 } 11 12 public function applyInternalEffects($object, $value) { 13 $object->setMessageText($value); 14 } 15 16 public function getTitle() { 17 return pht( 18 '%s updated the message text.', 19 $this->renderAuthor()); 20 } 21 22 public function hasChangeDetailView() { 23 return true; 24 } 25 26 public function getMailDiffSectionHeader() { 27 return pht('CHANGES TO MESSAGE'); 28 } 29 30 public function newChangeDetailView() { 31 $viewer = $this->getViewer(); 32 33 return id(new PhabricatorApplicationTransactionTextDiffDetailView()) 34 ->setViewer($viewer) 35 ->setOldText($this->getOldValue()) 36 ->setNewText($this->getNewValue()); 37 } 38 39}