Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F37690615
T64324
No One
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Authored By
Aklapper
Sep 11 2023, 2:00 PM
2023-09-11 14:00:09 (UTC+0)
Size
1 KB
Referenced Files
None
Subscribers
None
T64324
View Options
diff --git a/src/applications/phid/PhabricatorObjectHandle.php b/src/applications/phid/PhabricatorObjectHandle.php
index 577fd05692..f34bd317d5 100644
--- a/src/applications/phid/PhabricatorObjectHandle.php
+++ b/src/applications/phid/PhabricatorObjectHandle.php
@@ -338,6 +338,33 @@ final class PhabricatorObjectHandle
}
$circle = null;
+
+ ## WMF https://phabricator.wikimedia.org/T64324 start - Indicate new users
+ $userAccountAge = time() - $userCreated;
+ $userIsNew = $userAccountAge < (60*60*24*30); // 30 days
+
+ if ($this->getType() == PhabricatorPeopleUserPHIDType::TYPECONST) {
+ $query = id(new PhabricatorFeedQuery())
+ ->setViewer(PhabricatorUser::getOmnipotentUser())
+ ->withFilterPHIDs(array($this->getPHID()))
+ ->setLimit(11)
+ ->setReturnPartialResultsOnOverheat(true);
+ $stories = $query->execute();
+
+ if (count($stories) < 11 || $userIsNew) {
+ $circle = array(
+ phutil_tag(
+ 'span',
+ array(
+ 'class' => 'newcomer-star-but-irrelevant-as-no-css-defined',
+ ),
+ "\xE2\x98\x86"),
+ ' ',
+ );
+ }
+ }
+ ## WMF https://phabricator.wikimedia.org/T64324 end - Indicate new users
+
if ($this->availability != self::AVAILABILITY_FULL) {
$classes[] = 'handle-availability-'.$this->availability;
$circle = array(
File Metadata
Details
Attached
Mime Type
text/plain; charset=utf-8
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
11369698
Default Alt Text
T64324 (1 KB)
Attached To
Mode
P52415 T64324
Attached
Detach File
Event Timeline
Log In to Comment