diff options
author | John Livingston <38844060+JohnXLivingston@users.noreply.github.com> | 2019-08-23 09:05:30 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2019-08-23 09:05:30 +0200 |
commit | 20ec03846ddb40d8aeaa87fc92b8bd7994c3ecf7 (patch) | |
tree | 0bc9fef073f67cd60968f6ad0a180b13026e3b52 /server/lib/peertube-socket.ts | |
parent | d11c28a36b1382ea0a5d5e8d19a67e99b6b24de0 (diff) | |
download | PeerTube-20ec03846ddb40d8aeaa87fc92b8bd7994c3ecf7.tar.gz PeerTube-20ec03846ddb40d8aeaa87fc92b8bd7994c3ecf7.tar.zst PeerTube-20ec03846ddb40d8aeaa87fc92b8bd7994c3ecf7.zip |
fixes 2065: optimisation (#2073)
* fixes 2065: optimisation
* Update peertube-socket.ts
Diffstat (limited to 'server/lib/peertube-socket.ts')
-rw-r--r-- | server/lib/peertube-socket.ts | 3 |
1 files changed, 2 insertions, 1 deletions
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 { | |||
39 | 39 | ||
40 | if (!sockets) return | 40 | if (!sockets) return |
41 | 41 | ||
42 | const notificationMessage = notification.toFormattedJSON() | ||
42 | for (const socket of sockets) { | 43 | for (const socket of sockets) { |
43 | socket.emit('new-notification', notification.toFormattedJSON()) | 44 | socket.emit('new-notification', notificationMessage) |
44 | } | 45 | } |
45 | } | 46 | } |
46 | 47 | ||