From 0cc1f50170832d2d6b95f0df294e264e4866138b Mon Sep 17 00:00:00 2001 From: Bob Trahan Date: Thu, 6 Feb 2014 13:06:11 -0800 Subject: [PATCH] Herald - make flag color display Summary: It used to say "Mark with flag 7" or whatever, and now it says "Mark with flag Checkered" Test Plan: noted previous rule I made was more understandable Reviewers: epriestley Reviewed By: epriestley CC: Korvin, epriestley, aran Differential Revision: https://secure.phabricator.com/D8158 --- src/applications/herald/adapter/HeraldAdapter.php | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/applications/herald/adapter/HeraldAdapter.php b/src/applications/herald/adapter/HeraldAdapter.php index 5417958004..136a0b1cb0 100644 --- a/src/applications/herald/adapter/HeraldAdapter.php +++ b/src/applications/herald/adapter/HeraldAdapter.php @@ -1013,9 +1013,16 @@ abstract class HeraldAdapter { $target = array($target); } foreach ($target as $index => $val) { - $handle = idx($handles, $val); - if ($handle) { - $target[$index] = $handle->renderLink(); + switch ($action->getAction()) { + case self::ACTION_FLAG: + $target[$index] = PhabricatorFlagColor::getColorName($val); + break; + default: + $handle = idx($handles, $val); + if ($handle) { + $target[$index] = $handle->renderLink(); + } + break; } } $target = phutil_implode_html(', ', $target);