From 31343e61ceee871c6a8a95d3f16795997f0f5202 Mon Sep 17 00:00:00 2001 From: epriestley Date: Wed, 30 Jul 2014 17:12:28 -0700 Subject: [PATCH] Fix email for closing a blocking task Summary: Fixes T5751. Currently, we incorrectly overwrite `$xactions`. Test Plan: Closed a blocking task, got an email about the correct transaction set ("closed task; added comment") instead of an overwritten transaction set ("closed blocking task"). Reviewers: chad, btrahan Reviewed By: btrahan Subscribers: epriestley Maniphest Tasks: T5751 Differential Revision: https://secure.phabricator.com/D10088 --- .../maniphest/editor/ManiphestTransactionEditor.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/applications/maniphest/editor/ManiphestTransactionEditor.php b/src/applications/maniphest/editor/ManiphestTransactionEditor.php index 26f96e6844..0e06645fd6 100644 --- a/src/applications/maniphest/editor/ManiphestTransactionEditor.php +++ b/src/applications/maniphest/editor/ManiphestTransactionEditor.php @@ -258,9 +258,9 @@ final class ManiphestTransactionEditor $new = $unblock_xaction->getNewValue(); foreach ($blocked_tasks as $blocked_task) { - $xactions = array(); + $unblock_xactions = array(); - $xactions[] = id(new ManiphestTransaction()) + $unblock_xactions[] = id(new ManiphestTransaction()) ->setTransactionType(ManiphestTransaction::TYPE_UNBLOCK) ->setOldValue(array($object->getPHID() => $old)) ->setNewValue(array($object->getPHID() => $new)); @@ -275,7 +275,7 @@ final class ManiphestTransactionEditor ->setContentSource($this->getContentSource()) ->setContinueOnNoEffect(true) ->setContinueOnMissingFields(true) - ->applyTransactions($blocked_task, $xactions); + ->applyTransactions($blocked_task, $unblock_xactions); } } }