This project is archived and is in readonly mode.

#746 ✓wontfix

Controller Layout Used Erroneously When Similar Named File Exists

Reported by atrerus | August 2nd, 2008 @ 05:38 AM | in 2.x

If I have a controller named "customers" and a file in my layouts directory called "customers.html.erb.bak" the framework will decide to use the controller layout instead of falling through to the application layout. If "customers.html.erb" does not exist, an error will be reported and the page will not load successfully.

These file names cause it to fail:

  • customers.html

  • customers.html.asdf

  • customers.html.erb.asdf

While these do not:

  • customers.asdf

  • customers

Tested on a Dreamhost server with Rails 2.0.2 and ruby 1.8.5.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href=""></a>

People watching this ticket