class Rack::Cascade

def initialize(apps, cascade_for = [404, 405])

from an app, the next app is tried.
cascade_for: The statuses to use cascading for. If a response is received
apps: An enumerable of rack applications.

cascading. Arguments:
Set the apps to send requests to, and what statuses result in
def initialize(apps, cascade_for = [404, 405])
  @apps = []
  apps.each { |app| add app }
  @cascade_for = {}
  [*cascade_for].each { |status| @cascade_for[status] = true }
end