mirror of
https://github.com/discourse/discourse.git
synced 2024-12-22 13:43:58 +08:00
21 lines
448 B
Ruby
21 lines
448 B
Ruby
|
# frozen_string_literal: true
|
||
|
|
||
|
class ChangeSegmentCjkSiteSetting < ActiveRecord::Migration[6.1]
|
||
|
def up
|
||
|
execute <<~SQL
|
||
|
UPDATE site_settings
|
||
|
SET name = 'search_tokenize_chinese'
|
||
|
WHERE name = 'search_tokenize_chinese_japanese_korean'
|
||
|
SQL
|
||
|
|
||
|
execute <<~SQL
|
||
|
DELETE FROM site_settings
|
||
|
WHERE name = 'search_tokenize_chinese_japanese_korean'
|
||
|
SQL
|
||
|
end
|
||
|
|
||
|
def down
|
||
|
raise ActiveRecord::IrreversibleMigration
|
||
|
end
|
||
|
end
|