Skip to content

Ensure approver references are all present

Mark Chao requested to merge 1979-1-3-fix into master

What does this MR do?

Fix one bug of data migration in https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/8669 where an approver association is pointing to an no longer existing user_id.

When assigning using _ids =, the ids provided must all be present. However some data in approvers table are users which has been destroyed. Therefore Rails would raise exception.

The fix does extra checking to ensure user_ids and group_ids are all still present.

What are the relevant issue numbers?

#8647 (closed)

Does this MR meet the acceptance criteria?

Edited by Mark Chao

Merge request reports