Enable Lint/ShadowingOuterLocalVariable for Rubocop.

This commit is contained in:
Guo Xiang Tan
2018-09-04 10:16:21 +08:00
parent 2f5c21e28c
commit 8dc1463ab3
16 changed files with 70 additions and 59 deletions

View File

@ -273,8 +273,8 @@ class ImportScripts::Telligent < ImportScripts::Base
user_id: user_id,
created_at: row["DateCreated"],
closed: row["IsLocked"],
post_create_action: proc do |post|
topic = post.topic
post_create_action: proc do |action_post|
topic = action_post.topic
Jobs.enqueue_at(topic.pinned_until, :unpin_topic, topic_id: topic.id) if topic.pinned_until
url = "f/#{row['ForumId']}/t/#{row['ThreadId']}"
Permalink.create(url: url, topic_id: topic.id) unless Permalink.exists?(url: url)