feat: Use inbox image as avatar for the bot (#6859)
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
class MigrateEnvVarToChannelFeature < ActiveRecord::Migration[6.1]
|
||||
def change
|
||||
return unless ActiveModel::Type::Boolean.new.cast(ENV.fetch('USE_INBOX_AVATAR_FOR_BOT', false))
|
||||
|
||||
Channel::WebWidget.find_in_batches do |widget_batch|
|
||||
widget_batch.each do |widget|
|
||||
widget.use_inbox_avatar_for_bot = true
|
||||
widget.save!
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -10,7 +10,7 @@
|
||||
#
|
||||
# It's strongly recommended that you check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(version: 2023_04_04_030719) do
|
||||
ActiveRecord::Schema.define(version: 2023_04_07_191457) do
|
||||
|
||||
# These are extensions that must be enabled in order to support this database
|
||||
enable_extension "pg_stat_statements"
|
||||
|
||||
Reference in New Issue
Block a user