From a1ce52effccae4851593f1d9b83ca9bf826bf338 Mon Sep 17 00:00:00 2001 From: Joshua Peek Date: Tue, 20 Oct 2009 12:31:23 -0500 Subject: New routing dsl --- actionpack/lib/action_dispatch/routing/route_set.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'actionpack/lib/action_dispatch/routing/route_set.rb') diff --git a/actionpack/lib/action_dispatch/routing/route_set.rb b/actionpack/lib/action_dispatch/routing/route_set.rb index a6e46b1c78..90d7c208a5 100644 --- a/actionpack/lib/action_dispatch/routing/route_set.rb +++ b/actionpack/lib/action_dispatch/routing/route_set.rb @@ -208,9 +208,9 @@ module ActionDispatch clear! end - def draw + def draw(&block) clear! - yield Mapper.new(self) + Mapper.new(self).instance_exec(DeprecatedMapper.new(self), &block) @set.add_route(NotFound) install_helpers @set.freeze -- cgit v1.2.3