Commit ae539fe6 authored by Heinrich Lee Yu's avatar Heinrich Lee Yu

Merge branch 'remove_migrate_bio_to_user_details_ff' into 'master'

Remove migrate_bio_to_user_details FF

See merge request gitlab-org/gitlab!43309
parents 53244026 6089f196
---
name: migrate_bio_to_user_details
introduced_by_url:
rollout_issue_url:
group:
type: development
default_enabled: true
...@@ -66,8 +66,6 @@ class CleanupProjectsWithMissingNamespace < ActiveRecord::Migration[6.0] ...@@ -66,8 +66,6 @@ class CleanupProjectsWithMissingNamespace < ActiveRecord::Migration[6.0]
end end
def ensure_bio_is_assigned_to_user_details def ensure_bio_is_assigned_to_user_details
return if Feature.disabled?(:migrate_bio_to_user_details, default_enabled: true)
user_detail.bio = bio.to_s[0...255] user_detail.bio = bio.to_s[0...255]
end end
......
...@@ -13,8 +13,6 @@ module Gitlab ...@@ -13,8 +13,6 @@ module Gitlab
end end
def perform(start_id, stop_id) def perform(start_id, stop_id)
return if Feature.disabled?(:migrate_bio_to_user_details, default_enabled: true)
relation = User relation = User
.select("id AS user_id", "substring(COALESCE(bio, '') from 1 for 255) AS bio") .select("id AS user_id", "substring(COALESCE(bio, '') from 1 for 255) AS bio")
.where("(COALESCE(bio, '') IS DISTINCT FROM '')") .where("(COALESCE(bio, '') IS DISTINCT FROM '')")
......
...@@ -82,21 +82,4 @@ RSpec.describe Gitlab::BackgroundMigration::MigrateUsersBioToUserDetails, :migra ...@@ -82,21 +82,4 @@ RSpec.describe Gitlab::BackgroundMigration::MigrateUsersBioToUserDetails, :migra
expect(user_detail).to be_nil expect(user_detail).to be_nil
end end
context 'when `migrate_bio_to_user_details` feature flag is off' do
before do
stub_feature_flags(migrate_bio_to_user_details: false)
end
it 'does nothing' do
already_existing_user_details = user_details.where(user_id: [
user_has_different_details.id,
user_already_has_details.id
])
subject
expect(user_details.all).to match_array(already_existing_user_details)
end
end
end end
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