celluloid/reel — pull request #77 by tarcieri (2013-08-11 21:49:37+00:00)
Title: Separate Requests from WebSockets

This API has you first obtain a Reel::Request for a given connection, which may
be a WebSocket and may be potentially upgradable.

Where the old API went something like:

while request = connection.request
case request
when Reel::Request
...
when Reel::WebSocket
...
end
end

The new API works something like:

while request = connection.request
if request.websocket?
websocket = request.websocket
...
break
else
...
end
end