Skip to content

Fix Replace button form path

Igor Drozdov requested to merge id-fix-replace-file-button into master

What does this MR do and why?

Related issue: gitlab-com/gl-infra/production#6369 (closed)

We had an incident when users couldn't replace a file due to refactor_blob_viewer feature flag being enabled. This MR fixes Replace file button for the case when the FF is enabled.

The feature flag is disabled in tests: https://gitlab.com/gitlab-org/gitlab/blob/37dae5be2a7c83f9dbe4a6f58c168ac691a416b6/spec/features/projects/files/user_replaces_files_spec.rb#L20, that's why the bug hasn't been caught by them.

The MR fixes the bug, but in order to enable FF in tests, helper code must be fixed: https://gitlab.com/gitlab-org/gitlab/blob/ef31072ed5c96cebc7a70c9887d70c1c0a353ccc/spec/support/helpers/dropzone_helper.rb#L75, because dropzone file upload is implemented differently in Vue.

Edited by Igor Drozdov

Merge request reports

Loading