Improve goss-restorethread.rb to allow for restoring a given Gossamer Forums Forum Post / OP post_id
This commit is contained in:
parent
24b98174f0
commit
af520c8bdb
@ -277,6 +277,7 @@ class GossamerForumsImporter < ImportScripts::Base
|
||||
end
|
||||
|
||||
def update_db_topic_last_post_time(topic_id, last_post_time)
|
||||
puts "zzzzzzzzz1 #{topic_id} #{last_post_time}"
|
||||
@db.execute "INSERT OR REPLACE INTO topic_last_post_time_final2 (topic_id, last_post_time) VALUES (?, ?)", topic_id, last_post_time
|
||||
end
|
||||
|
||||
@ -1382,7 +1383,7 @@ class GossamerForumsImporter < ImportScripts::Base
|
||||
|
||||
sqlite_mutex.synchronize do
|
||||
# Update the database with the last post time and user for the topic
|
||||
puts "zzzz1"
|
||||
puts "zzzz1 #{current_topic_id} #{Time.at(row['post_time']).to_i}"
|
||||
update_db_topic_last_post_time(current_topic_id, Time.at(row['post_time']).to_i)
|
||||
update_db_topic_last_post_user(current_topic_id, discourse_user_id)
|
||||
puts "zzzz2"
|
||||
|
Loading…
Reference in New Issue
Block a user