From 7b089f7af453685a743106f3310ce4535f1d1963 Mon Sep 17 00:00:00 2001 From: David Taylor Date: Wed, 15 Aug 2018 15:50:55 +0100 Subject: [PATCH] FIX: Don't throw exception if welcome topic cannot be found --- lib/introduction_updater.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/introduction_updater.rb b/lib/introduction_updater.rb index 60de29f5318..002b52f06e0 100644 --- a/lib/introduction_updater.rb +++ b/lib/introduction_updater.rb @@ -34,7 +34,7 @@ protected topic_id = Topic.listable_topics.where(slug: 'welcome-to-discourse').pluck(:id) end - welcome_topic = Topic.find(topic_id).first + welcome_topic = Topic.where(id: topic_id).first return nil unless welcome_topic.present? post = welcome_topic.posts.where(post_number: 1).first