Commit 796bd5f7 authored by Ash McKenzie's avatar Ash McKenzie

Merge branch 'fix-import-status-endpoint-null-pointer' into 'master'

/import status REST endpoint: fix null-unsafe access to import_state

Closes #214302

See merge request gitlab-org/gitlab!29471
parents 327b4f73 cd22000a
...@@ -5,7 +5,7 @@ module API ...@@ -5,7 +5,7 @@ module API
class ProjectImportStatus < ProjectIdentity class ProjectImportStatus < ProjectIdentity
expose :import_status expose :import_status
expose :correlation_id do |project, _options| expose :correlation_id do |project, _options|
project.import_state.correlation_id project.import_state&.correlation_id
end end
# TODO: Use `expose_nil` once we upgrade the grape-entity gem # TODO: Use `expose_nil` once we upgrade the grape-entity gem
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment