Permalink
Browse files

[Issue #7] Fix gem not working with Thin

  • Loading branch information...
1 parent 4e2a1b7 commit 8189cf436713c78eef4ecec0473534ee46a40160 @tye committed Aug 9, 2012
Showing with 3 additions and 0 deletions.
  1. +3 −0 lib/rubyception/websocket_server.rb
@@ -20,6 +20,9 @@ def initialize
options = {
host: '0.0.0.0',
port: 3030 }
+ while defined?(Thin) && !EventMachine.reactor_running?
+ sleep 1
+ end
EventMachine::WebSocket.start(options) do |ws|
ws.onopen do
Rubyception::WebsocketServer.sockets << ws

0 comments on commit 8189cf4

Please sign in to comment.