summaryrefslogtreecommitdiff
path: root/app/controllers/projects/packages/package_files_controller.rb
blob: dd6d875cd1e892cd2d4c8d5ae18d54bfb50e49b7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
# frozen_string_literal: true

module Projects
  module Packages
    class PackageFilesController < ApplicationController
      include PackagesAccess
      include SendFileUpload

      def download
        package_file = project.package_files.find(params[:id])

        send_upload(package_file.file, attachment: package_file.file_name)
      end
    end
  end
end