Page MenuHomePhabricator

Add Mailtags to Paste
ClosedPublic

Authored by chad on Apr 13 2015, 10:05 PM.

Details

Summary

Fixes T7786. Adds very basic mailtag support.

Test Plan

Tested changing language, title to a Paste, didn't get notifications on my test account.

Diff Detail

Repository
rP Phabricator
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

chad retitled this revision from to Add Mailtags to Paste.
chad updated this object.
chad edited the test plan for this revision. (Show Details)
chad added reviewers: epriestley, btrahan.

I think we should separate "comment" out, but maybe lump "title" and "content" into a single category, and put "language" with "other"? So the options would be:

  • Content is changed (title or body).
  • Comment.
  • Other.

Particularly, my guess is that "comment" is much more interesting to separate out than "language".

I didn't know what magic text to write for COMMENT

You can look at, e.g., DifferentialTransaction->getMailTags() for an example. It should be:

PhabricatorTransactions::TYPE_COMMENT
chad edited edge metadata.
  • updates
src/applications/paste/editor/PhabricatorPasteEditor.php
160

...and then this one becomes PhabricatorPasteTransaction::MAILTAG_COMMENT

src/applications/paste/storage/PhabricatorPasteTransaction.php
12

Oh, sorry -- you do need to add MAILTAG_COMMENT here...

197

...and do:

case PhabricatorTransactions::TYPE_COMMENT:
  $tag[] = self::MAILTAG_COMMENT;

...here

haha, i sent this up and was having issues with testing. thanks for the notes.

epriestley edited edge metadata.
This revision is now accepted and ready to land.Apr 13 2015, 10:30 PM
This revision was automatically updated to reflect the committed changes.