Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Changeset 5248

Show
Ignore:
Timestamp:
10/09/06 00:56:13 (2 years ago)
Author:
david
Message:

Fixed that caches_action breaks with file extensions (closes #6257) [Catfish]

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/actionpack/lib/action_controller/caching.rb

    r5212 r5248  
    211211            if extention = action_cache_path.extension 
    212212              content_type = Mime::EXTENSION_LOOKUP[extention] 
    213               action_cache_path.controller.content_type = content_type.to_s 
     213              action_cache_path.controller.response.content_type = content_type.to_s 
    214214            end 
    215215          end 
  • trunk/actionpack/test/controller/action_caching_test.rb

    r4656 r5248  
    122122  end 
    123123   
     124  def test_file_extensions 
     125    get :index, :id => 'kitten.jpg'  
     126    get :index, :id => 'kitten.jpg' 
     127 
     128    assert_response :success 
     129  end 
     130   
    124131  private 
    125132