Sha256: 801857adfb32b71f2d480bf1ab916b262af7b07cf841e7409ab76d3f76ea00fd

Contents?: true

Size: 439 Bytes

Versions: 141

Compression:

Stored size: 439 Bytes

Contents

# frozen_string_literal: true

require "rack/body_proxy"

module ActionDispatch
  class Executor
    def initialize(app, executor)
      @app, @executor = app, executor
    end

    def call(env)
      state = @executor.run!
      begin
        response = @app.call(env)
        returned = response << ::Rack::BodyProxy.new(response.pop) { state.complete! }
      ensure
        state.complete! unless returned
      end
    end
  end
end

Version data entries

141 entries across 133 versions & 10 rubygems

Version Path
actionpack-6.1.4.4 lib/action_dispatch/middleware/executor.rb
actionpack-6.0.4.4 lib/action_dispatch/middleware/executor.rb
actionpack-6.1.4.3 lib/action_dispatch/middleware/executor.rb
actionpack-6.0.4.3 lib/action_dispatch/middleware/executor.rb
actionpack-6.0.4.2 lib/action_dispatch/middleware/executor.rb
actionpack-6.1.4.2 lib/action_dispatch/middleware/executor.rb
date_n_time_picker_activeadmin-0.1.2 vendor/bundle/ruby/2.6.0/gems/actionpack-6.1.4.1/lib/action_dispatch/middleware/executor.rb
date_n_time_picker_activeadmin-0.1.1 vendor/bundle/ruby/2.6.0/gems/actionpack-6.1.4.1/lib/action_dispatch/middleware/executor.rb
actionpack-7.0.0.alpha2 lib/action_dispatch/middleware/executor.rb
actionpack-7.0.0.alpha1 lib/action_dispatch/middleware/executor.rb
actionpack-6.1.4.1 lib/action_dispatch/middleware/executor.rb
actionpack-6.0.4.1 lib/action_dispatch/middleware/executor.rb
rails_mini_profiler-0.2.0 vendor/bundle/ruby/3.0.0/gems/actionpack-6.1.4/lib/action_dispatch/middleware/executor.rb
actionpack-6.1.4 lib/action_dispatch/middleware/executor.rb
actionpack-6.0.4 lib/action_dispatch/middleware/executor.rb
actionpack-5.2.6 lib/action_dispatch/middleware/executor.rb
actionpack-6.0.3.7 lib/action_dispatch/middleware/executor.rb
actionpack-6.1.3.2 lib/action_dispatch/middleware/executor.rb
actionpack-5.2.4.6 lib/action_dispatch/middleware/executor.rb
actionpack-6.1.3.1 lib/action_dispatch/middleware/executor.rb