Drop `EmailLogs#topic_id`.
This commit is contained in:
parent
7a2bf8e368
commit
01a63f8b4b
|
@ -239,4 +239,15 @@ Migration::ColumnDropper.drop(
|
|||
}
|
||||
)
|
||||
|
||||
Migration::ColumnDropper.drop(
|
||||
table: 'email_logs',
|
||||
after_migration: 'DropTopicIdOnEmailLogs',
|
||||
columns: %w{
|
||||
topic_id
|
||||
},
|
||||
on_drop: ->() {
|
||||
STDERR.puts "Removing superflous email_logs columns!"
|
||||
}
|
||||
)
|
||||
|
||||
Discourse.reset_active_record_cache
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
class DropTopicIdOnEmailLogs < ActiveRecord::Migration[5.2]
|
||||
def change
|
||||
remove_index :email_logs, :topic_id
|
||||
end
|
||||
end
|
Loading…
Reference in New Issue