diff options
Diffstat (limited to 'app/services/import/github/cancel_project_import_service.rb')
-rw-r--r-- | app/services/import/github/cancel_project_import_service.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/app/services/import/github/cancel_project_import_service.rb b/app/services/import/github/cancel_project_import_service.rb index 5dce5e73662..62cd0c95eaf 100644 --- a/app/services/import/github/cancel_project_import_service.rb +++ b/app/services/import/github/cancel_project_import_service.rb @@ -9,6 +9,8 @@ module Import if project.import_in_progress? project.import_state.cancel + metrics.track_canceled_import + success(project: project) else error(cannot_cancel_error_message, :bad_request) @@ -31,6 +33,10 @@ module Import project_status: project.import_state.status ) end + + def metrics + @metrics ||= Gitlab::Import::Metrics.new(:github_importer, project) + end end end end |