mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-12-11 08:11:15 -05:00
11 lines
233 B
Ruby
11 lines
233 B
Ruby
class EmbeddableHostSerializer < ApplicationSerializer
|
|
|
|
TO_SERIALIZE = [:id, :host, :path_whitelist, :category_id]
|
|
|
|
attributes *TO_SERIALIZE
|
|
|
|
TO_SERIALIZE.each do |attr|
|
|
define_method(attr) { object.send(attr) }
|
|
end
|
|
|
|
end
|