2
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2025-09-06 10:50:21 +08:00

DEV: set digest_attempted_at during migrations (#11369)

This commit is contained in:
Régis Hanol 2020-12-14 00:58:14 +01:00 committed by GitHub
parent b913afe5bb
commit a85d5edbf1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 4 deletions

View file

@ -737,6 +737,10 @@ class ImportScripts::Base
WHERE u1.user_id = user_stats.user_id
AND user_stats.topic_count <> sub.topic_count
SQL
puts "", "Updating user digest_attempted_at..."
DB.exec("UPDATE user_stats SET digest_attempted_at = now() WHERE digest_attempted_at IS NULL")
end
# scripts that are able to import last_seen_at from the source data should override this method