Append websocket items only if proper mode is set
This commit is contained in:
parent
135a04db24
commit
360a80b795
|
@ -55,5 +55,7 @@ exampleSocket.onopen = function (event) {
|
|||
};
|
||||
exampleSocket.onmessage = function (event) {
|
||||
item = JSON.parse(event.data);
|
||||
app.items.push(item);
|
||||
if (item.State === state) {
|
||||
app.items.push(item);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue