From 5001aadf4660f1b3985007ddb513c3119cccb145 Mon Sep 17 00:00:00 2001 From: epriestley Date: Mon, 23 Mar 2015 09:10:18 -0700 Subject: [PATCH] Throw a more helpful error for bad Differential actions Summary: Ref T7611. This should let us figure out the root cause, hopefully. Test Plan: iiam Reviewers: joshuaspence, btrahan Reviewed By: btrahan Subscribers: epriestley Maniphest Tasks: T7611 Differential Revision: https://secure.phabricator.com/D12124 --- .../differential/editor/DifferentialTransactionEditor.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/applications/differential/editor/DifferentialTransactionEditor.php b/src/applications/differential/editor/DifferentialTransactionEditor.php index c3dd3c3ace..7363a46780 100644 --- a/src/applications/differential/editor/DifferentialTransactionEditor.php +++ b/src/applications/differential/editor/DifferentialTransactionEditor.php @@ -249,6 +249,11 @@ final class DifferentialTransactionEditor case DifferentialAction::ACTION_CLAIM: $object->setAuthorPHID($this->getActingAsPHID()); return; + default: + throw new Exception( + pht( + 'Differential action "%s" is not a valid action!', + $xaction->getNewValue())); } break; }