summaryrefslogtreecommitdiff
path: root/app/services/files/base_service.rb
blob: 38231f66009d4c3a1d26031173de96c2c1c94eff (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
module Files
  class BaseService < Commits::CreateService
    def initialize(*args)
      super

      @author_email = params[:author_email]
      @author_name = params[:author_name]
      @commit_message = params[:commit_message]

      @file_path = params[:file_path]
      @previous_path = params[:previous_path]

      @file_content = params[:file_content]
      @file_content = Base64.decode64(@file_content) if params[:file_content_encoding] == 'base64'
    end
  end
end