From 20ec03846ddb40d8aeaa87fc92b8bd7994c3ecf7 Mon Sep 17 00:00:00 2001 From: John Livingston <38844060+JohnXLivingston@users.noreply.github.com> Date: Fri, 23 Aug 2019 09:05:30 +0200 Subject: [PATCH] fixes 2065: optimisation (#2073) * fixes 2065: optimisation * Update peertube-socket.ts --- server/lib/peertube-socket.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server/lib/peertube-socket.ts b/server/lib/peertube-socket.ts index ad2bb4845..26ced351f 100644 --- a/server/lib/peertube-socket.ts +++ b/server/lib/peertube-socket.ts @@ -39,8 +39,9 @@ class PeerTubeSocket { if (!sockets) return + const notificationMessage = notification.toFormattedJSON() for (const socket of sockets) { - socket.emit('new-notification', notification.toFormattedJSON()) + socket.emit('new-notification', notificationMessage) } } -- 2.41.0