From fc26668cd98c49f091b145ff94bedb7301a6f894 2007-12-18 18:04:10 From: Jean-Philippe Lang Date: 2007-12-18 18:04:10 Subject: [PATCH] Fixed: upload doesn't work in "Files" section. git-svn-id: http://redmine.rubyforge.org/svn/branches/0.6-stable@1009 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/controllers/projects_controller.rb b/app/controllers/projects_controller.rb index 7b1e4ef..0df442c 100644 --- a/app/controllers/projects_controller.rb +++ b/app/controllers/projects_controller.rb @@ -339,7 +339,7 @@ class ProjectsController < ApplicationController def add_file if request.post? @version = @project.versions.find_by_id(params[:version_id]) - attachments = attach_files(@issue, params[:attachments]) + attachments = attach_files(@version, params[:attachments]) Mailer.deliver_attachments_added(attachments) if !attachments.empty? && Setting.notified_events.include?('file_added') redirect_to :controller => 'projects', :action => 'list_files', :id => @project end