if aspect is not dropped it redirects back for consistency
This commit is contained in:
parent
4256ea34b6
commit
d34964651c
1 changed files with 1 additions and 5 deletions
|
|
@ -49,14 +49,10 @@ class AspectsController < ApplicationController
|
||||||
begin
|
begin
|
||||||
current_user.drop_aspect @aspect
|
current_user.drop_aspect @aspect
|
||||||
flash[:notice] = I18n.t 'aspects.destroy.success',:name => @aspect.name
|
flash[:notice] = I18n.t 'aspects.destroy.success',:name => @aspect.name
|
||||||
|
redirect_to root_url
|
||||||
rescue RuntimeError => e
|
rescue RuntimeError => e
|
||||||
flash[:error] = e.message
|
flash[:error] = e.message
|
||||||
end
|
|
||||||
|
|
||||||
if current_user.getting_started
|
|
||||||
redirect_to :back
|
redirect_to :back
|
||||||
else
|
|
||||||
respond_with :location => aspects_manage_path
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue