Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15422208
D10928.id26248.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D10928.id26248.diff
View Options
diff --git a/src/applications/transactions/editor/PhabricatorApplicationTransactionCommentEditor.php b/src/applications/transactions/editor/PhabricatorApplicationTransactionCommentEditor.php
--- a/src/applications/transactions/editor/PhabricatorApplicationTransactionCommentEditor.php
+++ b/src/applications/transactions/editor/PhabricatorApplicationTransactionCommentEditor.php
@@ -71,22 +71,26 @@
$xaction->save();
$xaction->attachComment($comment);
- $object = id(new PhabricatorObjectQuery())
- ->withPHIDs(array($xaction->getObjectPHID()))
- ->setViewer($this->getActor())
- ->executeOne();
- if ($object &&
- $object instanceof PhabricatorApplicationTransactionInterface) {
- $editor = $object->getApplicationTransactionEditor();
- $editor->setActor($this->getActor());
- $support_xactions = $editor->getExpandedSupportTransactions(
- $object,
- $xaction);
- if ($support_xactions) {
- $editor
- ->setContentSource($this->getContentSource())
- ->setContinueOnNoEffect(true)
- ->applyTransactions($object, $support_xactions);
+ // For comment edits, we need to make sure there are no automagical
+ // transactions like adding mentions or projects.
+ if ($new_version > 1) {
+ $object = id(new PhabricatorObjectQuery())
+ ->withPHIDs(array($xaction->getObjectPHID()))
+ ->setViewer($this->getActor())
+ ->executeOne();
+ if ($object &&
+ $object instanceof PhabricatorApplicationTransactionInterface) {
+ $editor = $object->getApplicationTransactionEditor();
+ $editor->setActor($this->getActor());
+ $support_xactions = $editor->getExpandedSupportTransactions(
+ $object,
+ $xaction);
+ if ($support_xactions) {
+ $editor
+ ->setContentSource($this->getContentSource())
+ ->setContinueOnNoEffect(true)
+ ->applyTransactions($object, $support_xactions);
+ }
}
}
$xaction->endReadLocking();
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mar 23 2025, 6:41 AM (4 w, 6 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7428664
Default Alt Text
D10928.id26248.diff (2 KB)
Attached To
Mode
D10928: Transactions - don't bother checking for fancy transactions on comment create
Attached
Detach File
Event Timeline
Log In to Comment