Module: RailsMini::Ext::RouterMappings
- Defined in:
- lib/rails_mini/ext.rb
Instance Method Summary collapse
Instance Method Details
#match(path, options = nil, &blk) ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/rails_mini/ext.rb', line 7 def match(path,=nil,&blk) if blk ||= {} controller = Class.new(ActionController::Base) controller.send(:define_method,path.to_sym,blk) [:to] ||= controller.action(path.to_sym) end super(path,) end |