summaryrefslogtreecommitdiff
path: root/app/controllers/projects/boards_controller.rb
blob: 0035633b774ce0fdfac6bcda6406b65dcf7c7011 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
class Projects::BoardsController < Projects::ApplicationController
  include IssuableCollections
  
  respond_to :html

  before_action :authorize_read_board!, only: [:show]

  def show
    ::Boards::CreateService.new(project, current_user).execute
  end

  private

  def authorize_read_board!
    return access_denied! unless can?(current_user, :read_board, project)
  end
end