From 5b814f20438b6e2f734d42f48475083b657e9d44 Mon Sep 17 00:00:00 2001 From: Jan Segre <jan@vialink.com.br> Date: Thu, 25 Apr 2013 17:07:41 -0300 Subject: [PATCH] Fixing error 500 on /groups and /teams. Although these urls do not exist they were being mapped with rails resources. I've added an exception not to add the index routes. Now they will yield 404 errors instead of 500 ones when trying to access /groups or /teams. --- config/routes.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config/routes.rb b/config/routes.rb index 18475e03277..4838d97a4ea 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -133,7 +133,7 @@ Gitlab::Application.routes.draw do # # Groups Area # - resources :groups, constraints: {id: /(?:[^.]|\.(?!atom$))+/, format: /atom/} do + resources :groups, constraints: {id: /(?:[^.]|\.(?!atom$))+/, format: /atom/}, except: [:index] do member do get :issues get :merge_requests @@ -146,7 +146,7 @@ Gitlab::Application.routes.draw do # # Teams Area # - resources :teams, constraints: {id: /(?:[^.]|\.(?!atom$))+/, format: /atom/} do + resources :teams, constraints: {id: /(?:[^.]|\.(?!atom$))+/, format: /atom/}, except: [:index] do member do get :issues get :merge_requests -- GitLab