lib/active_memoize/instance.rb in active_memoize-2.0.2 vs lib/active_memoize/instance.rb in active_memoize-2.0.3
- old
+ new
@@ -78,15 +78,13 @@
cache.values
end
private
- # rubocop:disable Metrics/LineLength
def caller_locals(block)
local_vars = block.binding.local_variables
local_vars.flat_map { |name| [name, block.binding.local_variable_get(name)] }
end
- # rubocop:enable Metrics/LineLength
def caller_method
val = caller(2..2).first[CALLER_METHOD_REGEX, 1]
return val unless val.include?('<top (required)>')