1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-09-20 09:18:48 +02:00

Disable notifications for your own actions

Summary:
Actions you made no longer show up in the lighting-bolt
dropdown. I didn't touch realtime notifications but they're transient
enough that it shouldn't matter too much?

I wonder, though, whether it would be more useful to have the
notifications still present but automatically marked read.

Test Plan:
Create notifications; muck around in the database; check that
the dropdown and list pages are displaying correctly.

Reviewers: epriestley

Reviewed By: epriestley

CC: aran, Korvin

Maniphest Tasks: T1402

Differential Revision: https://secure.phabricator.com/D3360
This commit is contained in:
Alan Huang 2012-08-22 09:07:22 -07:00
parent f8e28fae01
commit 03dafec74f

View file

@ -103,7 +103,12 @@ final class PhabricatorFeedStoryPublisher {
private function insertNotifications($chrono_key) {
if (!$this->subscribedPHIDs) {
$subscribed_phids = $this->subscribedPHIDs;
$subscribed_phids = array_diff(
$subscribed_phids,
array($this->storyAuthorPHID));
if (!$subscribed_phids) {
return;
}
@ -116,7 +121,7 @@ final class PhabricatorFeedStoryPublisher {
$sql = array();
$conn = $notif->establishConnection('w');
foreach (array_unique($this->subscribedPHIDs) as $user_phid) {
foreach (array_unique($subscribed_phids) as $user_phid) {
$sql[] = qsprintf(
$conn,
'(%s, %s, %s, %d)',