Skip to content

Commit 7b54174

Browse files
authored
Merge pull request #59395 from nextcloud/backport/59330/stable32
[stable32] fix: update email button text to 'Open shared item'
2 parents faa4ee1 + 443bc17 commit 7b54174

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

apps/sharebymail/lib/ShareByMailProvider.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,7 @@ protected function sendEmail(IShare $share, array $emails): void {
354354
}
355355

356356
$emailTemplate->addBodyButton(
357-
$this->l->t('Open %s', [$filename]),
357+
$this->l->t('Open shared item'),
358358
$link
359359
);
360360

@@ -528,7 +528,7 @@ protected function sendNote(IShare $share): void {
528528
$link = $this->urlGenerator->linkToRouteAbsolute('files_sharing.sharecontroller.showShare',
529529
['token' => $share->getToken()]);
530530
$emailTemplate->addBodyButton(
531-
$this->l->t('Open %s', [$filename]),
531+
$this->l->t('Open shared item'),
532532
$link
533533
);
534534

apps/sharebymail/tests/ShareByMailProviderTest.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1328,7 +1328,7 @@ public function testSendMailNotificationWithSameUserAndUserEmail(): void {
13281328
->expects($this->once())
13291329
->method('addBodyButton')
13301330
->with(
1331-
'Open file.txt',
1331+
'Open shared item',
13321332
'https://example.com/file.txt'
13331333
);
13341334
$message
@@ -1450,7 +1450,7 @@ public function testSendMailNotificationWithSameUserAndUserEmailAndNote(): void
14501450
->expects($this->once())
14511451
->method('addBodyButton')
14521452
->with(
1453-
'Open file.txt',
1453+
'Open shared item',
14541454
'https://example.com/file.txt'
14551455
);
14561456
$message
@@ -1577,7 +1577,7 @@ public function testSendMailNotificationWithSameUserAndUserEmailAndExpiration():
15771577
->expects($this->once())
15781578
->method('addBodyButton')
15791579
->with(
1580-
'Open file.txt',
1580+
'Open shared item',
15811581
'https://example.com/file.txt'
15821582
);
15831583
$message
@@ -1684,7 +1684,7 @@ public function testSendMailNotificationWithDifferentUserAndNoUserEmail(): void
16841684
->expects($this->once())
16851685
->method('addBodyButton')
16861686
->with(
1687-
'Open file.txt',
1687+
'Open shared item',
16881688
'https://example.com/file.txt'
16891689
);
16901690
$message
@@ -1781,7 +1781,7 @@ public function testSendMailNotificationWithSameUserAndUserEmailAndReplyToDesact
17811781
->expects($this->once())
17821782
->method('addBodyButton')
17831783
->with(
1784-
'Open file.txt',
1784+
'Open shared item',
17851785
'https://example.com/file.txt'
17861786
);
17871787
$message
@@ -1882,7 +1882,7 @@ public function testSendMailNotificationWithDifferentUserAndNoUserEmailAndReplyT
18821882
->expects($this->once())
18831883
->method('addBodyButton')
18841884
->with(
1885-
'Open file.txt',
1885+
'Open shared item',
18861886
'https://example.com/file.txt'
18871887
);
18881888
$message

0 commit comments

Comments
 (0)