Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F13977533
D13220.id31963.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D13220.id31963.diff
View Options
diff --git a/src/applications/conpherence/phid/PhabricatorConpherenceThreadPHIDType.php b/src/applications/conpherence/phid/PhabricatorConpherenceThreadPHIDType.php
--- a/src/applications/conpherence/phid/PhabricatorConpherenceThreadPHIDType.php
+++ b/src/applications/conpherence/phid/PhabricatorConpherenceThreadPHIDType.php
@@ -19,9 +19,7 @@
protected function buildQueryForObjects(
PhabricatorObjectQuery $query,
array $phids) {
-
return id(new ConpherenceThreadQuery())
- ->needParticipantCache(true)
->withPHIDs($phids);
}
@@ -33,7 +31,7 @@
foreach ($handles as $phid => $handle) {
$thread = $objects[$phid];
- $title = $thread->getDisplayTitle($query->getViewer());
+ $title = $thread->getStaticTitle();
$monogram = $thread->getMonogram();
$handle->setName($title);
diff --git a/src/applications/conpherence/storage/ConpherenceThread.php b/src/applications/conpherence/storage/ConpherenceThread.php
--- a/src/applications/conpherence/storage/ConpherenceThread.php
+++ b/src/applications/conpherence/storage/ConpherenceThread.php
@@ -199,6 +199,23 @@
return PhabricatorUser::getDefaultProfileImageURI();
}
+ /**
+ * Get a thread title which doesn't require handles to be attached.
+ *
+ * This is a less rich title than @{method:getDisplayTitle}, but does not
+ * require handles to be attached. We use it to build thread handles without
+ * risking cycles or recursion while querying.
+ *
+ * @return string Lower quality human-readable title.
+ */
+ public function getStaticTitle() {
+ $title = $this->getTitle();
+ if (strlen($title)) {
+ return $title;
+ }
+
+ return pht('Private Correspondence');
+ }
/**
* Get the thread's display title for a user.
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Oct 19 2024, 7:02 PM (4 w, 3 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6713963
Default Alt Text
D13220.id31963.diff (1 KB)
Attached To
Mode
D13220: Try using a less-rich but less-risky thread title in Conpherence handles
Attached
Detach File
Event Timeline
Log In to Comment