mirror of
https://github.com/discourse/discourse.git
synced 2025-06-06 12:04:41 +08:00
DEV: Apply syntax_tree formatting to app/*
This commit is contained in:
@ -1,13 +1,9 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class EmbeddableHostSerializer < ApplicationSerializer
|
||||
|
||||
TO_SERIALIZE = [:id, :host, :allowed_paths, :class_name, :category_id]
|
||||
TO_SERIALIZE = %i[id host allowed_paths class_name category_id]
|
||||
|
||||
attributes *TO_SERIALIZE
|
||||
|
||||
TO_SERIALIZE.each do |attr|
|
||||
define_method(attr) { object.public_send(attr) }
|
||||
end
|
||||
|
||||
TO_SERIALIZE.each { |attr| define_method(attr) { object.public_send(attr) } }
|
||||
end
|
||||
|
Reference in New Issue
Block a user