diff options
author | pluralcafe-docker <git@plural.cafe> | 2019-01-31 19:01:31 +0000 |
---|---|---|
committer | pluralcafe-docker <git@plural.cafe> | 2019-01-31 19:01:31 +0000 |
commit | 9e04595911a5565a38452061f7c573c4f8917766 (patch) | |
tree | 85bac2a16c9c2371679d43311d9d6b069c988e94 /db | |
parent | 50dc62ea3a36039463032aa2e712471859d9d9b6 (diff) | |
parent | 48d00ac0d9ad703fa3605337b0866c8ce6f21b28 (diff) |
Merge branch 'glitch'
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20181116173541_copy_account_stats.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/db/migrate/20181116173541_copy_account_stats.rb b/db/migrate/20181116173541_copy_account_stats.rb index bb523fbbd..8e27eb11b 100644 --- a/db/migrate/20181116173541_copy_account_stats.rb +++ b/db/migrate/20181116173541_copy_account_stats.rb @@ -44,7 +44,7 @@ class CopyAccountStats < ActiveRecord::Migration[5.2] # uniqueness violations that we need to skip over Account.unscoped.select('id, statuses_count, following_count, followers_count, created_at, updated_at').find_each do |account| begin - params = [[nil, account.id], [nil, account.statuses_count], [nil, account.following_count], [nil, account.followers_count], [nil, account.created_at], [nil, account.updated_at]] + params = [[nil, account.id], [nil, account[:statuses_count]], [nil, account[:following_count]], [nil, account[:followers_count]], [nil, account.created_at], [nil, account.updated_at]] exec_insert('INSERT INTO account_stats (account_id, statuses_count, following_count, followers_count, created_at, updated_at) VALUES ($1, $2, $3, $4, $5, $6)', nil, params) rescue ActiveRecord::RecordNotUnique next |