Skip to content

Commit

Permalink
Restore the Entry#bytesize comments removed in rails#41882
Browse files Browse the repository at this point in the history
  • Loading branch information
byroot committed Apr 12, 2021
1 parent 6a5fb7d commit 93e5388
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion activesupport/lib/active_support/cache.rb
Expand Up @@ -845,7 +845,9 @@ def expires_at=(value)
end
end

def bytesize # :nodoc:
# Returns the size of the cached value. This could be less than
# <tt>value.bytesize</tt> if the data is compressed.
def bytesize
case value
when NilClass
0
Expand Down

0 comments on commit 93e5388

Please sign in to comment.