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/Chat
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2019-04-01 17:49:57 +0300
committerJoas Schilling <coding@schilljs.com>2019-04-01 17:49:57 +0300
commitd7179bed2b593c54068458871d637b72a60852ce (patch)
tree18540e965776923daa0804a8bc57aaec9673dbb2 /lib/Chat
parentd991e993aa640c885acab0a6e8750333ac64ea1c (diff)
Catch exception for unknown message
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/Chat')
-rw-r--r--lib/Chat/Parser/Listener.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/Chat/Parser/Listener.php b/lib/Chat/Parser/Listener.php
index db5076dfd..61928a392 100644
--- a/lib/Chat/Parser/Listener.php
+++ b/lib/Chat/Parser/Listener.php
@@ -54,7 +54,12 @@ class Listener {
/** @var Changelog $parser */
$parser = \OC::$server->query(Changelog::class);
- $parser->parseMessage($message);
+ try {
+ $parser->parseMessage($message);
+ $event->stopPropagation();
+ } catch (\OutOfBoundsException $e) {
+ // Unknown message, ignore
+ }
}, -75);
$dispatcher->addListener(MessageParser::class . '::parseMessage', function(GenericEvent $event) {