diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2019-10-07 06:05:14 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-10-07 06:05:14 +0200 |
commit | ebe574d5b57c647450cab3d4ca2e8ca52c4fb3fe (patch) | |
tree | 25333ed59bbab747c6ba91b5db55ad658aeebaab /db | |
parent | 6c9b4f6b7710cbbdafcceafb59dfef0be6baba65 (diff) |
Fix old migration trying to use new column due to default status scope (#12095)
Fix #12087
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20181024224956_migrate_account_conversations.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/db/migrate/20181024224956_migrate_account_conversations.rb b/db/migrate/20181024224956_migrate_account_conversations.rb index b718f9e1d..d4bc3b91d 100644 --- a/db/migrate/20181024224956_migrate_account_conversations.rb +++ b/db/migrate/20181024224956_migrate_account_conversations.rb @@ -52,6 +52,6 @@ class MigrateAccountConversations < ActiveRecord::Migration[5.2] end def notifications_about_direct_statuses - Notification.joins(mention: :status).where(activity_type: 'Mention', statuses: { visibility: :direct }) + Notification.joins('INNER JOIN mentions ON mentions.id = notifications.activity_id INNER JOIN statuses ON statuses.id = mentions.status_id').where(activity_type: 'Mention', statuses: { visibility: :direct }) end end |