Fix wording of undeliverable push notifications

Signed-off-by: Joas Schilling <coding@schilljs.com>
pull/33770/head
Joas Schilling 3 years ago
parent 809f448ef7
commit 85eb3b2920
No known key found for this signature in database
GPG Key ID: 74434EFE0D2E2205
  1. 2
      core/Controller/LoginController.php
  2. 4
      core/js/setupchecks.js
  3. 2
      lib/private/Notification/Manager.php

@ -151,7 +151,7 @@ class LoginController extends Controller {
if (!is_array($loginMessages)) {
$loginMessages = [[], []];
}
$loginMessages[1][] = $this->l10n->t('This community release of Nextcloud is unsupported and instant notifications are unavailable.');
$loginMessages[1][] = $this->l10n->t('This community release of Nextcloud is unsupported and push notifications are limited.');
}
if (is_array($loginMessages)) {
[$errors, $messages] = $loginMessages;

@ -261,7 +261,9 @@
}
if (!data.isFairUseOfFreePushService) {
messages.push({
msg: t('core', 'This is the unsupported community build of Nextcloud. Given the size of this instance, performance, reliability and scalability cannot be guaranteed. Push notifications have been disabled to avoid overloading our free service. Learn more about the benefits of Nextcloud Enterprise at nextcloud.com/enterprise.'),
msg: t('core', 'This is the unsupported community build of Nextcloud. Given the size of this instance, performance, reliability and scalability cannot be guaranteed. Push notifications are limited to avoid overloading our free service. Learn more about the benefits of Nextcloud Enterprise at {linkstart}https://nextcloud.com/enterprise{linkend}.')
.replace('{linkstart}', '<a target="_blank" rel="noreferrer noopener" class="external" href="https://nextcloud.com/enterprise">')
.replace('{linkend}', '</a>'),
type: OC.SetupChecks.MESSAGE_TYPE_ERROR
});
}

@ -305,7 +305,7 @@ class Manager implements IManager {
* users overload our infrastructure. For this reason we have to rate-limit the
* use of push notifications. If you need this feature, consider using Nextcloud Enterprise.
*/
$isFairUse = $this->subscription->delegateHasValidSubscription() || $this->userManager->countSeenUsers() < 5000;
$isFairUse = $this->subscription->delegateHasValidSubscription() || $this->userManager->countSeenUsers() < 500;
$pushAllowed = $isFairUse ? 'yes' : 'no';
$this->cache->set('push_fair_use', $pushAllowed, 3600);
}

Loading…
Cancel
Save