soffes/bully — pull request #15 by aschuch (2013-04-25 15:54:25+00:00)
Title: Better connection close handling based on pusher protocol

See the [Pusher Websocket Protocol](http://pusher.com/docs/pusher_protocol) for further details.

* changed to Pusher protocol version 6 (now supports close codes with error messages)
* added better connection close handling (e.g. do not try to reconnect if the app key is not valid, as this would put unnecessary load on the Pusher servers)
* if the connection is manually closed by the user, do not try to reconnect automatically (to impose the same behaviour as the Pusher Javascript client)
* changed ```bullyClientDidDisconnect:``` in favor of ```bullyClientDidDisconnect:withError:``` to expose why the client was disconnected