Fix url generation error on hook invalid create

This commit is contained in:
skv 2014-04-06 19:42:24 +04:00
parent bc40efa19d
commit 4cc2afdf2e
1 changed files with 1 additions and 1 deletions

View File

@ -18,7 +18,7 @@ class Projects::HooksController < Projects::ApplicationController
if @hook.valid?
redirect_to project_hooks_path(@project)
else
@hooks = @project.hooks
@hooks = @project.hooks.select(&:persisted?)
render :index
end
end