Page MenuHomePhabricator

D15589.diff
No OneTemporary

D15589.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
Sun, Nov 10, 9:29 PM (1 w, 1 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6713210
Default Alt Text
D15589.diff (1 KB)

Event Timeline