lib/jammit/routes.rb in jammit-0.4.4 vs lib/jammit/routes.rb in jammit-0.5.0

- old
+ new

@@ -1,15 +1,22 @@ module Jammit + # Rails 2.x routing module. Rails 3.x routes are in rails/routes.rb. module Routes # Jammit uses a single route in order to slow down Rails' routing speed # by the absolute minimum. In your config/routes.rb file, call: # Jammit::Routes.draw(map) # Passing in the routing "map" object. def self.draw(map) - map.jammit "/#{Jammit.package_path}/:package.:extension", - :controller => 'jammit', :action => 'package' + map.jammit "/#{Jammit.package_path}/:package.:extension", { + :controller => 'jammit', + :action => 'package', + :requirements => { + # A hack to allow extension to include "." + :extension => /.+/ + } + } end end end \ No newline at end of file