debian-mirror-gitlab/lib/gitlab/import_export/uploads_saver.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

27 lines
515 B
Ruby
Raw Normal View History

2019-02-15 15:39:39 +05:30
# frozen_string_literal: true
2016-06-22 15:30:34 +05:30
module Gitlab
module ImportExport
class UploadsSaver
2022-06-21 17:19:12 +05:30
include DurationMeasuring
2016-06-22 15:30:34 +05:30
def initialize(project:, shared:)
@project = project
@shared = shared
end
def save
2022-06-21 17:19:12 +05:30
with_duration_measuring do
Gitlab::ImportExport::UploadsManager.new(
project: @project,
shared: @shared
).save
end
2021-06-08 01:23:25 +05:30
rescue StandardError => e
2016-06-22 15:30:34 +05:30
@shared.error(e)
false
end
end
end
end