lib/angelo/mustermann.rb in angelo-0.1.14 vs lib/angelo/mustermann.rb in angelo-0.1.15

- old
+ new

@@ -10,11 +10,11 @@ base.extend ClassMethods base.class_eval do def_delegator :@responder, :mustermann end - [Responder, WebsocketResponder].each do |res| + [Responder, Responder::Websocket, Responder::Eventsource].each do |res| res.class_eval do attr_accessor :mustermann end end end @@ -27,9 +27,14 @@ routes[m][path] = Responder.new &block end end def websocket path, &block + path = ::Mustermann.new path + super path, &block + end + + def eventsource path, &block path = ::Mustermann.new path super path, &block end def routes