4 ms·ws.onclose = function() { // websocket is closed. }; someone reformatted the code without checking...by cracki 17y agows.onclose = function() { // websocket is closed. }; someone reformatted the code without checking...