Fix url generation error on hook invalid create
This commit is contained in:
		
							parent
							
								
									bc40efa19d
								
							
						
					
					
						commit
						4cc2afdf2e
					
				| 
						 | 
					@ -18,7 +18,7 @@ class Projects::HooksController < Projects::ApplicationController
 | 
				
			||||||
    if @hook.valid?
 | 
					    if @hook.valid?
 | 
				
			||||||
      redirect_to project_hooks_path(@project)
 | 
					      redirect_to project_hooks_path(@project)
 | 
				
			||||||
    else
 | 
					    else
 | 
				
			||||||
      @hooks = @project.hooks
 | 
					      @hooks = @project.hooks.select(&:persisted?)
 | 
				
			||||||
      render :index
 | 
					      render :index
 | 
				
			||||||
    end
 | 
					    end
 | 
				
			||||||
  end
 | 
					  end
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue