Skip to content

Commit

Permalink
Dont send subscription messages if websocket not active
Browse files Browse the repository at this point in the history
  • Loading branch information
klis87 committed Feb 20, 2021
1 parent 914c068 commit bc5cbc2
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ export default ({

const actionPayload = getActionPayload(action);

if (actionPayload.subscription && ws) {
if (actionPayload.subscription && ws && active) {
ws.send(
JSON.stringify(
onSend
Expand Down

0 comments on commit bc5cbc2

Please sign in to comment.