Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorMike Greiling <mike@pixelcog.com>2019-06-27 03:13:01 +0300
committerMike Greiling <mike@pixelcog.com>2019-06-27 03:13:01 +0300
commite688f3db660e783a64ba7aadee13238ceb84f595 (patch)
tree9303994e384299d1c907c659e6ad5943e0f03ccb /config
parent6f44b8fcdab5498172d4414aabbf627c4e36711f (diff)
parent9be95e2b2f72ca481848823d3856b4518fd9743a (diff)
Merge branch 'dz-remove-deprecated-user-routes' into 'master'
Remove deprecated user routes See merge request gitlab-org/gitlab-ce!30044
Diffstat (limited to 'config')
-rw-r--r--config/routes/snippets.rb2
-rw-r--r--config/routes/user.rb9
2 files changed, 1 insertions, 10 deletions
diff --git a/config/routes/snippets.rb b/config/routes/snippets.rb
index 81bc890d86b..ba6da3ac57e 100644
--- a/config/routes/snippets.rb
+++ b/config/routes/snippets.rb
@@ -17,5 +17,5 @@ resources :snippets, concerns: :awardable do
end
end
-get '/s/:username', to: redirect('u/%{username}/snippets'),
+get '/s/:username', to: redirect('users/%{username}/snippets'),
constraints: { username: /[a-zA-Z.0-9_\-]+(?<!\.atom)/ }
diff --git a/config/routes/user.rb b/config/routes/user.rb
index e0ae264e2c0..f93a3fc6161 100644
--- a/config/routes/user.rb
+++ b/config/routes/user.rb
@@ -48,15 +48,6 @@ scope(constraints: { username: Gitlab::PathRegex.root_namespace_route_regex }) d
get :activity
get '/', to: redirect('%{username}'), as: nil
end
-
- # Compatibility with old routing
- # TODO (dzaporozhets): remove in 10.0
- get '/u/:username', to: redirect('%{username}')
- # TODO (dzaporozhets): remove in 9.0
- get '/u/:username/groups', to: redirect('users/%{username}/groups')
- get '/u/:username/projects', to: redirect('users/%{username}/projects')
- get '/u/:username/snippets', to: redirect('users/%{username}/snippets')
- get '/u/:username/contributed', to: redirect('users/%{username}/contributed')
end
constraints(::Constraints::UserUrlConstrainer.new) do