Skip to content

Commit 274cb66

Browse files
committed
Edits per beauby [ci skip]
1 parent 6331769 commit 274cb66

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

lib/active_model/serializer.rb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,11 +51,11 @@ def self.digest_caller_file(caller_line)
5151
class_attribute :_attributes_keys # @api private : maps attribute value to explict key name, @see Serializer#attribute
5252
self._attributes_keys ||= {}
5353
serializer.class_attribute :_cache # @api private : the cache object
54-
serializer.class_attribute :_fragmented # @api private :
54+
serializer.class_attribute :_fragmented # @api private : @see ::fragmented
5555
serializer.class_attribute :_cache_key # @api private : when present, is first item in cache_key
5656
serializer.class_attribute :_cache_only # @api private : when fragment caching, whitelists cached_attributes. Cannot combine with except
5757
serializer.class_attribute :_cache_except # @api private : when fragment caching, blacklists cached_attributes. Cannot combine with only
58-
serializer.class_attribute :_cache_options # @api private : Used by CachedSerializer, passed to _cache.fetch
58+
serializer.class_attribute :_cache_options # @api private : used by CachedSerializer, passed to _cache.fetch
5959
# _cache_options include:
6060
# expires_in
6161
# compress
@@ -153,11 +153,11 @@ def self.cache(options = {})
153153

154154
# @param resource [ActiveRecord::Base, ActiveModelSerializers::Model]
155155
# @return [ActiveModel::Serializer]
156-
# Preferentially retuns
156+
# Preferentially returns
157157
# 1. resource.serializer
158-
# 2. ArraySerializer for a collection
158+
# 2. ArraySerializer when resource is a collection
159159
# 3. options[:serializer]
160-
# 4. lookup serializer by class (i.e. resource is a class)
160+
# 4. lookup serializer when resource is a Class
161161
def self.serializer_for(resource, options = {})
162162
if resource.respond_to?(:serializer_class)
163163
resource.serializer_class

0 commit comments

Comments
 (0)