Make rubocop happy again.

This commit is contained in:
Guo Xiang Tan
2018-06-07 13:28:18 +08:00
parent c6c1ef71c1
commit ad5082d969
79 changed files with 3155 additions and 3155 deletions

View File

@ -81,12 +81,12 @@ class AdminUserActionSerializer < ApplicationSerializer
private
# we need this to handle deleted topics which aren't loaded via the .includes(:topic)
# because Rails 4 "unscoped" support is bugged (cf. https://github.com/rails/rails/issues/13775)
def topic
return @topic if @topic
@topic = object.topic || Topic.with_deleted.find(object.topic_id)
@topic
end
# we need this to handle deleted topics which aren't loaded via the .includes(:topic)
# because Rails 4 "unscoped" support is bugged (cf. https://github.com/rails/rails/issues/13775)
def topic
return @topic if @topic
@topic = object.topic || Topic.with_deleted.find(object.topic_id)
@topic
end
end