lib/rack/websocket/application.rb in websocket-rack-0.1.2 vs lib/rack/websocket/application.rb in websocket-rack-0.1.3

- old
+ new

@@ -1,7 +1,20 @@ module Rack module WebSocket class Application + + class << self + def new(*args) + if args.last == {:real_run => true} + args.shift + super(*args) + else + proc do |env| + self.new(*(args << {:real_run => true})).call(env) + end + end + end + end DEFAULT_OPTIONS = {} attr_accessor :options def on_open; end # Fired when a client is connected. \ No newline at end of file