class Dependabot::PullRequestCreator::Codecommit

def branch_exists?(branch_name)

def branch_exists?(branch_name)
  @branch_ref ||= T.let(
    codecommit_client_for_source.branch(branch_name),
    T.nilable(String)
  )
  !@branch_ref.nil?
  rescue Aws::CodeCommit::Errors::BranchDoesNotExistException
    false
end