Sha256: 9fec92d25cd6bc52a22346ad46ec0f531a0349d10b25b5510ef521af8e9d26f3

Contents?: true

Size: 361 Bytes

Versions: 1

Compression:

Stored size: 361 Bytes

Contents

module Golf
  class Rack
    
    def initialize(app = nil)
      @app = app if app
    end

    def call(env)
      if env["REQUEST_METHOD"] == "GET" and env["PATH_INFO"] == "/component.js"
        ['200', { 'Content-Type' => 'application/javascript', 'Content-Length' => '5'}, ['asasd']]
      else
        @app.call(env) if @app
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
golf-0.0.4 lib/golf/rack.rb