mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-19 03:50:54 +01:00
Fix spurious timeline entry for badges
Summary: Fixes T11164. At least, this fixes it locally for me. I don't know how to code. Copy Pasta! Test Plan: Change name, don't see extra timeline entry on quality set anymore. Reviewers: epriestley Reviewed By: epriestley Subscribers: Korvin Maniphest Tasks: T11164 Differential Revision: https://secure.phabricator.com/D16169
This commit is contained in:
parent
3bb3170a2c
commit
a75eea7637
2 changed files with 4 additions and 4 deletions
|
@ -47,7 +47,7 @@ final class PhabricatorBadgesEditor
|
|||
case PhabricatorBadgesTransaction::TYPE_ICON:
|
||||
return $object->getIcon();
|
||||
case PhabricatorBadgesTransaction::TYPE_QUALITY:
|
||||
return $object->getQuality();
|
||||
return (int)$object->getQuality();
|
||||
case PhabricatorBadgesTransaction::TYPE_STATUS:
|
||||
return $object->getStatus();
|
||||
case PhabricatorBadgesTransaction::TYPE_AWARD:
|
||||
|
|
|
@ -105,14 +105,14 @@ final class PhabricatorBadgesTransaction
|
|||
}
|
||||
break;
|
||||
case self::TYPE_QUALITY:
|
||||
$qual_new = PhabricatorBadgesQuality::getQualityName($new);
|
||||
$qual_old = PhabricatorBadgesQuality::getQualityName($old);
|
||||
if ($old === null) {
|
||||
return pht(
|
||||
'%s set the quality for this badge as "%s".',
|
||||
$this->renderHandleLink($author_phid),
|
||||
$new);
|
||||
$qual_new);
|
||||
} else {
|
||||
$qual_new = PhabricatorBadgesQuality::getQualityName($new);
|
||||
$qual_old = PhabricatorBadgesQuality::getQualityName($old);
|
||||
return pht(
|
||||
'%s updated the quality for this badge from "%s" to "%s".',
|
||||
$this->renderHandleLink($author_phid),
|
||||
|
|
Loading…
Reference in a new issue