Sha256: 817102087f8cd7fdb28fdd186f68f334d1e41e820421766009572fecf583051d
Contents?: true
Size: 551 Bytes
Versions: 7
Compression:
Stored size: 551 Bytes
Contents
module ActiveRemote module Serializers module JSON # Returns a json representation of the whitelisted publishable attributes. def as_json(options = {}) json_attributes = _publishable_attributes || attributes.keys json_methods = json_attributes.reject { |attribute| attributes.key?(attribute) } json_attributes -= json_methods default_options = { :only => json_attributes, :methods => json_methods } default_options.merge!(options) super(default_options) end end end end
Version data entries
7 entries across 7 versions & 1 rubygems