提示信息数组 flatten

This commit is contained in:
lizanle 2015-04-17 14:39:30 +08:00
parent 5d627bf6f2
commit 17838acddb
1 changed files with 1 additions and 1 deletions

View File

@ -116,7 +116,7 @@ class VersionsController < ApplicationController
end end
else else
respond_to do |format| respond_to do |format|
format.html { flash[:error] = @version.errors.full_messages.to_s format.html { flash[:error] = @version.errors.full_messages.flatten.to_s
redirect_to settings_project_url(@project, :tab => 'versions') } redirect_to settings_project_url(@project, :tab => 'versions') }
format.js { render :action => 'new' } format.js { render :action => 'new' }
format.api { render_validation_errors(@version) } format.api { render_validation_errors(@version) }