Skip to content

Commit 39dbeac

Browse files
committed
fixup! feat(mentions): allow teams to be mentioned
1 parent e0762b9 commit 39dbeac

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

Diff for: lib/Notification/Notifier.php

+4-4
Original file line numberDiff line numberDiff line change
@@ -775,8 +775,8 @@ protected function parseChatMessage(INotification $notification, Room $room, Par
775775

776776
$subject = $l->t('{user} mentioned group {group} in conversation {call}');
777777
} elseif ($notification->getSubject() === 'mention_team') {
778-
// $circlesManager = OC::$server->getCircleManager();
779-
// $groupName = $this->groupManager->getDisplayName($subjectParameters['sourceId']) ?? $subjectParameters['sourceId'];
778+
// $circlesManager = OC::$server->getCircleManager();
779+
// $groupName = $this->groupManager->getDisplayName($subjectParameters['sourceId']) ?? $subjectParameters['sourceId'];
780780
$richSubjectParameters['team'] = [
781781
'type' => 'circle',
782782
'id' => $subjectParameters['sourceId'],
@@ -800,8 +800,8 @@ protected function parseChatMessage(INotification $notification, Room $room, Par
800800

801801
$subject = $l->t('A deleted user mentioned group {group} in conversation {call}');
802802
} elseif ($notification->getSubject() === 'mention_team') {
803-
// $circlesManager = OC::$server->getCircleManager();
804-
// $groupName = $this->groupManager->getDisplayName($subjectParameters['sourceId']) ?? $subjectParameters['sourceId'];
803+
// $circlesManager = OC::$server->getCircleManager();
804+
// $groupName = $this->groupManager->getDisplayName($subjectParameters['sourceId']) ?? $subjectParameters['sourceId'];
805805
$richSubjectParameters['team'] = [
806806
'type' => 'circle',
807807
'id' => $subjectParameters['sourceId'],

Diff for: tests/integration/features/bootstrap/FeatureContext.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2313,7 +2313,7 @@ public function userSendsMessageToRoom(string $user, string $sendingMode, string
23132313
$message = str_replace('{$LOCAL_URL}', $this->localServerUrl, $message);
23142314
$message = str_replace('{$LOCAL_REMOTE_URL}', $this->localRemoteServerUrl, $message);
23152315
$message = str_replace('{$REMOTE_URL}', $this->remoteServerUrl, $message);
2316-
if(str_contains($message, '@"TEAM_ID(')) {
2316+
if (str_contains($message, '@"TEAM_ID(')) {
23172317
$result = preg_match('/TEAM_ID\(([^)]+)\)/', $message, $matches);
23182318
if ($result) {
23192319
$message = str_replace($matches[0], self::$createdTeams[$this->currentServer][$matches[1]], $message);

0 commit comments

Comments
 (0)