Permalink
Browse files

Using always locale prefix for now.

TODO: Make it a configuration option.
  • Loading branch information...
1 parent b29f1ec commit de61f84c818e1fcca2fe9c6053b9009bdd58c5b1 @tute committed Aug 29, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/route_translator/route_set/translator.rb
@@ -105,7 +105,7 @@ def request_method_array(reg)
def translate_path(path, locale)
final_optional_segments = path.slice!(/(\(.+\))$/)
new_path = path.split("/").map{|seg| translate_path_segment(seg, locale)}.join('/')
- new_path = "/#{locale.downcase}#{new_path}" unless default_locale?(locale)
+ new_path = "/#{locale.downcase}#{new_path}" # unless default_locale?(locale) # TODO: MAke this option configurable
new_path = "/" if new_path.blank?
"#{new_path}#{final_optional_segments}"
end

0 comments on commit de61f84

Please sign in to comment.