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

namespaces_controller.rb « controllers « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: c59a2401cefa36351745da02591a50bfa845204e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
class NamespacesController < ApplicationController
  skip_before_filter :authenticate_user!

  def show
    namespace = Namespace.find_by(path: params[:id])

    unless namespace
      return render_404
    end

    if namespace.type == "Group"
      redirect_to group_path(namespace)
    else
      redirect_to user_path(namespace.owner)
    end
  end
end