mirror of
https://github.com/discourse/discourse.git
synced 2025-02-06 03:18:23 +00:00
4ba93aac66
This is a follow up to commit 87c1e98571631d83e0d9f0846bd95a2c7e9bce87 which introduced different fields for primary and flair groups. Before that, primary group was used as a flair group too.
12 lines
237 B
Ruby
12 lines
237 B
Ruby
# frozen_string_literal: true
|
|
|
|
class SetUsersFlairGroupId < ActiveRecord::Migration[6.1]
|
|
def change
|
|
execute <<~SQL
|
|
UPDATE users
|
|
SET flair_group_id = primary_group_id
|
|
WHERE flair_group_id IS NULL
|
|
SQL
|
|
end
|
|
end
|