Skip to content

Commit

Permalink
use #each_value for greater efficiency
Browse files Browse the repository at this point in the history
  • Loading branch information
joelnordell committed Nov 15, 2015
1 parent b2ab831 commit fcae2ac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/fast_cache/cache.rb
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def empty?
#
# @return [self]
def clear
@data.values.map(&:value).map(&@cleanup) if @cleanup
@data.each_value(&@cleanup) if @cleanup
@data.clear
@expires_at.clear
self
Expand Down

0 comments on commit fcae2ac

Please sign in to comment.