Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/spreed.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2020-10-28 23:48:44 +0300
committerJoas Schilling <coding@schilljs.com>2020-10-28 23:52:25 +0300
commit449c7d2222fa39f72d72ac8d2c5895e0dec1ae52 (patch)
tree744475282c68e7c9280b0d9a3096b5fad95bba16 /lib
parent3caa7ca676c6022ce36bd09bfb2cfafe079da146 (diff)
Add a note why ICommentsManager needs to be injected in this one place
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/Chat/Parser/UserMention.php9
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/Chat/Parser/UserMention.php b/lib/Chat/Parser/UserMention.php
index f4985099f..9f83f996e 100644
--- a/lib/Chat/Parser/UserMention.php
+++ b/lib/Chat/Parser/UserMention.php
@@ -24,7 +24,6 @@ declare(strict_types=1);
namespace OCA\Talk\Chat\Parser;
-use OCA\Talk\Chat\CommentsManager;
use OCA\Talk\Exceptions\ParticipantNotFoundException;
use OCA\Talk\GuestManager;
use OCA\Talk\Model\Message;
@@ -39,7 +38,13 @@ use OCP\IUserManager;
*/
class UserMention {
- /** @var ICommentsManager */
+ /**
+ * Do NOT inject OCA\Talk\Chat\CommentsManager here
+ * otherwise the display name resolvers are lost
+ * and mentions are not replaced anymore.
+ *
+ * @var ICommentsManager
+ */
private $commentsManager;
/** @var IUserManager */
private $userManager;