Pārlūkot izejas kodu

Fix old migration trying to use new column due to default status scope (#12095)

Fix #12087
master
Eugen Rochko 2 mēnešus atpakaļ
vecāks
revīzija
ebe574d5b5
Revīzijas autora e-pasta adrese nav piesaistīta nevienam kontam

+ 1
- 1
db/migrate/20181024224956_migrate_account_conversations.rb Parādīt failu

@@ -52,6 +52,6 @@ class MigrateAccountConversations < ActiveRecord::Migration[5.2]
52 52
   end
53 53
 
54 54
   def notifications_about_direct_statuses
55
-    Notification.joins(mention: :status).where(activity_type: 'Mention', statuses: { visibility: :direct })
55
+    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 })
56 56
   end
57 57
 end

Notiek ielāde…
Atcelt
Saglabāt