Differential - return a better response for validation error cases
Summary: Fixes T6989. Basically return a nice dialogue like we do for "NoEffect" transactions. This is a little prettier than the other dialogue was. Also, stop adding TYPE_EDGE as a transaction type as we end up having it 2x, which then makes the error get validated 2x. Test Plan: tried to add myself as a reviewer and got a nice error message. Reviewers: chad, epriestley Reviewed By: epriestley Subscribers: Korvin, epriestley Maniphest Tasks: T6989 Differential Revision: https://secure.phabricator.com/D11448
This commit is contained in:
@@ -127,8 +127,9 @@ final class DifferentialCommentSaveController
|
||||
->setCancelURI($revision_uri)
|
||||
->setException($ex);
|
||||
} catch (PhabricatorApplicationTransactionValidationException $ex) {
|
||||
// TODO: Provide a nice Response for rendering these in a clean way.
|
||||
throw $ex;
|
||||
return id(new PhabricatorApplicationTransactionValidationResponse())
|
||||
->setCancelURI($revision_uri)
|
||||
->setException($ex);
|
||||
}
|
||||
|
||||
$user = $request->getUser();
|
||||
|
||||
Reference in New Issue
Block a user