Correction of an earlier commit

This commit is contained in:
Alexey Verkhovsky 2005-07-21 01:16:06 +00:00
parent 55c1254627
commit 659f4a4cc5

View file

@ -1,7 +1,7 @@
# Create a route to DEFAULT_WEB, if such is specified; also register a generic route # Create a route to DEFAULT_WEB, if such is specified; also register a generic route
def connect_to_web(map, generic_path, generic_routing_options) def connect_to_web(map, generic_path, generic_routing_options)
if defined? DEFAULT_WEB if defined? DEFAULT_WEB
explicit_path = generic_path.gsub(':web', DEFAULT_WEB) explicit_path = generic_path.gsub(/:web\/?/, '')
explicit_routing_options = generic_routing_options.merge(:web => DEFAULT_WEB) explicit_routing_options = generic_routing_options.merge(:web => DEFAULT_WEB)
map.connect(explicit_path, explicit_routing_options) map.connect(explicit_path, explicit_routing_options)
end end