Method: Commits::CommitPatchService#initialize

Defined in:
app/services/commits/commit_patch_service.rb

#initialize(*args) ⇒ CommitPatchService

Requires:

  • project: Project to be committed into

  • user: User that will be the committer

  • params:

    • branch_name: String the branch that will be committed into

    • start_branch: String the branch that will be started from

    • patches: Gitlab::Git::Patches::Collection that contains the patches



12
13
14
15
16
# File 'app/services/commits/commit_patch_service.rb', line 12

def initialize(*args)
  super

  @patches = Gitlab::Git::Patches::Collection.new(Array(params[:patches]))
end