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

blob_controller.rb « projects « controllers « app - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 878f25c7c03da2532bb960722ba9c8b777fdb9b6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# Controller for viewing a file's blame
class Projects::BlobController < Projects::ApplicationController
  include ExtractsPath

  # Authorize
  before_filter :authorize_read_project!
  before_filter :authorize_code_access!
  before_filter :require_non_empty_project

  def show
    @blob = Gitlab::Git::Blob.find(@repository, @commit.id, @path)

    not_found! unless @blob
  end
end