@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Improve error messaging for empty Conpherence threads

Summary: Fixes T7275. This makes the error stuff a little more consistent with other modern UIs.

Test Plan: {F307286}

Reviewers: chad, btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T7275

Differential Revision: https://secure.phabricator.com/D11778

+9 -2
+9 -2
src/applications/conpherence/controller/ConpherenceNewController.php
··· 12 12 $message = ''; 13 13 $e_participants = null; 14 14 $e_message = null; 15 + $errors = array(); 15 16 16 17 // this comes from ajax requests from all over. should be a single phid. 17 18 ··· 29 30 foreach ($error_codes as $error_code) { 30 31 switch ($error_code) { 31 32 case ConpherenceEditor::ERROR_EMPTY_MESSAGE: 32 - $e_message = true; 33 + $e_message = pht('Required'); 34 + $errors[] = pht( 35 + 'You can not send an empty message.'); 33 36 break; 34 37 case ConpherenceEditor::ERROR_EMPTY_PARTICIPANTS: 35 - $e_participants = true; 38 + $e_participants = pht('Required'); 39 + $errors[] = pht( 40 + 'You must choose at least one recipient for your '. 41 + 'message.'); 36 42 break; 37 43 } 38 44 } ··· 69 75 70 76 $dialog = id(new AphrontDialogView()) 71 77 ->setWidth(AphrontDialogView::WIDTH_FORM) 78 + ->setErrors($errors) 72 79 ->setUser($user) 73 80 ->setTitle($title) 74 81 ->addCancelButton($cancel_uri)