]> cat aescling's git repositories - mastodon.git/commitdiff
Fix streaming server only working for streams allowing local-only toots
authorThibaut Girka <thib@sitedethib.com>
Tue, 7 Jul 2020 18:30:40 +0000 (20:30 +0200)
committerThibG <thib@sitedethib.com>
Tue, 7 Jul 2020 18:31:45 +0000 (20:31 +0200)
streaming/index.js

index 6e75a2e807292a50768281ba80d35a3c5768dd7e..f69064e33d6154edea0ddc953748b5a05688cd72 100644 (file)
@@ -394,7 +394,7 @@ const startWorker = (workerId) => {
       }
 
       // Only send local-only statuses to logged-in users
-      if (event === 'update' && payload.local_only && !req.accountId || !allowLocalOnly) {
+      if (event === 'update' && payload.local_only && !(req.accountId && allowLocalOnly)) {
         log.silly(req.requestId, `Message ${payload.id} filtered because it was local-only`);
         return;
       }