Show
Ignore:
Timestamp:
12/17/07 17:38:44 (1 year ago)
Author:
yann
Message:

tests pass with Rails 2.0.2 (change yours views extenstion, exemple: *.html.en.erb or *.xml.en.builder)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/lib/globalize/rails/action_view.rb

    r179 r182  
    66    # Name of file extensions which are handled internally in rails. Other types 
    77    # like liquid has to register through register_handler. 
    8     @@re_extension = /\.(rjs|rhtml|rxml)$/ 
     8    @@re_extension = /\.(erb|rjs|builder)$/ 
    99     
    1010    @@globalize_path_cache = {} 
     
    3737        return cached if cached 
    3838 
    39         if use_full_path 
    40           template_path_without_extension, template_extension = path_and_extension(template_path) 
    41            
     39        template_path_without_extension, template_extension = path_and_extension(template_path) 
     40        if use_full_path   
    4241          if template_extension 
    4342            template_file_name = full_template_path(template_path_without_extension, template_extension) 
     
    4847            end 
    4948            template_file_name = full_template_path(template_path, template_extension) 
    50             template_extension = template_extension.gsub(/^\w+\./, '') # strip off any formats 
     49            template_extension = template_extension.gsub(/^.+\./, '') # strip off any formats 
    5150          end 
    5251        else