fix style
This commit is contained in:
parent
71dfb3b7e4
commit
58a63d9fd0
1 changed files with 4 additions and 4 deletions
|
|
@ -14,18 +14,18 @@ module Admin
|
||||||
@conference.use_difficulty_levels = false
|
@conference.use_difficulty_levels = false
|
||||||
@conference.save!
|
@conference.save!
|
||||||
flash[:error] = "You cannot enable the usage of difficulty levels without having set any levels."
|
flash[:error] = "You cannot enable the usage of difficulty levels without having set any levels."
|
||||||
redirect_to(admin_conference_difficulty_levels_path(:conference_id => @conference.short_title))
|
redirect_to(admin_conference_difficulty_levels_path(conference_id: @conference.short_title))
|
||||||
rescue ActiveRecord::RecordInvalid
|
rescue ActiveRecord::RecordInvalid
|
||||||
flash[:error] = "Something went wrong. Difficulty Levels update failed."
|
flash[:error] = "Something went wrong. Difficulty Levels update failed."
|
||||||
redirect_to(admin_conference_difficulty_levels_path(:conference_id => @conference.short_title))
|
redirect_to(admin_conference_difficulty_levels_path(conference_id: @conference.short_title))
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
flash[:notice] = "Difficulty Levels were successfully updated."
|
flash[:notice] = "Difficulty Levels were successfully updated."
|
||||||
redirect_to(admin_conference_difficulty_levels_path(:conference_id => @conference.short_title))
|
redirect_to(admin_conference_difficulty_levels_path(conference_id: @conference.short_title))
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
flash[:error] = "Difficulty Levels update failed."
|
flash[:error] = "Difficulty Levels update failed."
|
||||||
redirect_to(admin_conference_difficulty_levels_path(:conference_id => @conference.short_title))
|
redirect_to(admin_conference_difficulty_levels_path(conference_id: @conference.short_title))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue