Page MenuHomePhabricator

D15589.id37579.diff
No OneTemporary

D15589.id37579.diff

diff --git a/src/applications/people/controller/PhabricatorPeopleProfileViewController.php b/src/applications/people/controller/PhabricatorPeopleProfileViewController.php
--- a/src/applications/people/controller/PhabricatorPeopleProfileViewController.php
+++ b/src/applications/people/controller/PhabricatorPeopleProfileViewController.php
@@ -190,13 +190,13 @@
->execute();
$awards = mpull($awards, null, 'getBadgePHID');
- $badge_phids = mpull($awards, 'getBadgePHID');
- $badges = id(new PhabricatorBadgesQuery())
- ->setViewer($viewer)
- ->withPHIDs($badge_phids)
- ->withStatuses(array(PhabricatorBadgesBadge::STATUS_ACTIVE))
- ->execute();
- $badges = mpull($badges, null, 'getPHID');
+ $badges = array();
+ foreach ($awards as $award) {
+ $badge = $award->getBadge();
+ if ($badge->getStatus() == PhabricatorBadgesBadge::STATUS_ACTIVE) {
+ $badges[$award->getBadgePHID()] = $badge;
+ }
+ }
}
if (count($badges)) {

File Metadata

Mime Type
text/plain
Expires
Thu, Dec 26, 9:25 AM (11 h, 52 m)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6927614
Default Alt Text
D15589.id37579.diff (1 KB)

Event Timeline