This commit is contained in:
Nicolas Bally 2021-06-11 16:32:37 +02:00
parent 917fddae4e
commit 4af6425f42

View File

@ -45,9 +45,9 @@ class ForumTopic < ActiveRecord::Base
end end
ForumUser.where(:follow_new_topics => true).each do |forum_user| ForumUser.where(:follow_new_topics => true).each do |forum_user|
if folowed_topic = FolowedTopic.where(:forum_topic_id => topic.id).first if folowed_topic = FollowedTopic.where(:forum_topic_id => topic.id).first
else else
folowed_topic = FolowedTopic.create(:forum_topic_id => topic.id) folowed_topic = FollowedTopic.create(:forum_topic_id => topic.id)
end end
folowed_topic.save folowed_topic.save