SocketCluster / socketcluster-client

JavaScript client for SocketCluster
MIT License
293 stars 91 forks source link

optimize _onMessage #57

Closed mattkrick closed 8 years ago

mattkrick commented 8 years ago

remove try catch. this.parse refers to sc-formatter which already does the try/catch stuff. By taking it out of _onMessage V8 can optimize this & we'll get a little CPU speed boost on the client. Test it to verify it works for your projects.

I promise I'll get around to rewriting the client soon :smile:

jondubois commented 8 years ago

Thanks!