Requesting /attachments/1.all does not work in Rails 3. It was changed here:
https://github.com/rails/rails/commit/7e280c3bff8ac25f1c1938aeaeb1d0b4c0fbb726
The use case is a show action such as:
def show @attachment = Attachment.find(params[:id])
respond_to do |format| format.html format.any { download } end end
The pros of using this approach is take advantage of Cancan and InheritedResources defaults. What do you thing about it?