mirror of
https://github.com/redmine/redmine.git
synced 2025-11-10 23:36:01 +01:00
shorten long line of GroupsController
git-svn-id: http://svn.redmine.org/redmine/trunk@20217 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -66,11 +66,14 @@ class GroupsController < ApplicationController
|
||||
|
||||
respond_to do |format|
|
||||
if @group.save
|
||||
format.html {
|
||||
format.html do
|
||||
flash[:notice] = l(:notice_successful_create)
|
||||
redirect_to(params[:continue] ? new_group_path : groups_path)
|
||||
}
|
||||
format.api { render :action => 'show', :status => :created, :location => group_url(@group) }
|
||||
end
|
||||
format.api do
|
||||
render(:action => 'show', :status => :created,
|
||||
:location => group_url(@group))
|
||||
end
|
||||
else
|
||||
format.html { render :action => "new" }
|
||||
format.api { render_validation_errors(@group) }
|
||||
|
||||
Reference in New Issue
Block a user