Removed the index action from both the projects hook and services controllers

This commit is contained in:
Jose Ivan Vargas 2017-01-18 12:09:32 -06:00
parent 373411d18d
commit 0af9943314
2 changed files with 2 additions and 9 deletions

View file

@ -6,10 +6,6 @@ class Projects::HooksController < Projects::ApplicationController
layout "project_settings"
def index
redirect_to namespace_project_settings_integrations_path(@project.namespace, @project)
end
def create
@hook = @project.hooks.new(hook_params)
@hook.save
@ -18,7 +14,8 @@ class Projects::HooksController < Projects::ApplicationController
redirect_to namespace_project_settings_integrations_path(@project.namespace, @project)
else
@hooks = @project.hooks.select(&:persisted?)
render :index
flash[:alert] = @hook.errors.full_messages.join.html_safe
redirect_to namespace_project_settings_integrations_path(@project.namespace, @project)
end
end

View file

@ -9,10 +9,6 @@ class Projects::ServicesController < Projects::ApplicationController
layout "project_settings"
def index
redirect_to namespace_project_settings_integrations_path(@project.namespace, @project)
end
def edit
end