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

Audit - another partial fix to commit re-parsing bug

Summary: Ref T6350. We build $sql based on whose subscribed. If no one is subscribed, then we have no query to run.

Test Plan: observed one error disappearing from my daemon log. Also, more doing it live.

Reviewers: epriestley, chad

Reviewed By: chad

Subscribers: Korvin, epriestley

Maniphest Tasks: T6350

Differential Revision: https://secure.phabricator.com/D10731
This commit is contained in:
Bob Trahan 2014-10-20 17:39:19 -07:00
parent ec82ad2d16
commit d248bc47cf

View file

@ -164,13 +164,16 @@ final class PhabricatorFeedStoryPublisher {
$mark_read); $mark_read);
} }
if ($sql) {
queryfx( queryfx(
$conn, $conn,
'INSERT INTO %T (primaryObjectPHID, userPHID, chronologicalKey, hasViewed) 'INSERT INTO %T '.
VALUES %Q', '(primaryObjectPHID, userPHID, chronologicalKey, hasViewed) '.
'VALUES %Q',
$notif->getTableName(), $notif->getTableName(),
implode(', ', $sql)); implode(', ', $sql));
} }
}
private function sendNotification($chrono_key, array $subscribed_phids) { private function sendNotification($chrono_key, array $subscribed_phids) {
$data = array( $data = array(