# File actionpack/lib/action_dispatch/routing/mapper.rb, line 872
def controller(controller, options = {})
if options.empty?
begin
@scope = @scope.new(controller: controller)
yield
ensure
@scope = @scope.parent
end
else
ActiveSupport::Deprecation.warn "#controller with options is deprecated. If you need to pass more options than the controller name use #scope."
options[:controller] = controller
scope(options) { yield }
end
end