From 0b9a878250d79101756d881d15d22acda2dbeddc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=B4me=20Chilliet?= Date: Thu, 25 Aug 2022 18:32:20 +0200 Subject: [PATCH] Flag repair errors as error level in eventSource->send MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Côme Chilliet --- core/ajax/update.php | 2 +- lib/public/IEventSource.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/ajax/update.php b/core/ajax/update.php index 0fe398df7bf..56dffef409c 100644 --- a/core/ajax/update.php +++ b/core/ajax/update.php @@ -92,7 +92,7 @@ class FeedBackHandler { } elseif ($event instanceof RepairWarningEvent) { $this->eventSource->send('notice', $this->l10n->t('Repair warning:') . ' ' . $event->getMessage()); } elseif ($event instanceof RepairErrorEvent) { - $this->eventSource->send('notice', $this->l10n->t('Repair error:') . ' ' . $event->getMessage()); + $this->eventSource->send('error', $this->l10n->t('Repair error:') . ' ' . $event->getMessage()); } } } diff --git a/lib/public/IEventSource.php b/lib/public/IEventSource.php index 85f09837125..879b365cc77 100644 --- a/lib/public/IEventSource.php +++ b/lib/public/IEventSource.php @@ -35,7 +35,7 @@ interface IEventSource { /** * send a message to the client * - * @param string $type + * @param string $type One of success, notice, error, failure and done. Used in core/js/update.js * @param mixed $data * * if only one parameter is given, a typeless message will be send with that parameter as data