mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
DEV: move send => public_send in lib folder
This handles most of the cases in `lib` where we were using send instead of public_send
This commit is contained in:
@@ -25,7 +25,7 @@ module ActiveSupport
|
||||
found = true
|
||||
data = cache.fetch(arguments) { found = false }
|
||||
unless found
|
||||
cache[arguments] = data = send(uncached, *arguments)
|
||||
cache[arguments] = data = public_send(uncached, *arguments)
|
||||
end
|
||||
# so cache is never corrupted
|
||||
data.dup
|
||||
@@ -48,7 +48,7 @@ module ActiveSupport
|
||||
|
||||
define_method(method_name) do |*arguments|
|
||||
ActiveSupport::Inflector.clear_memoize!
|
||||
send(orig, *arguments)
|
||||
public_send(orig, *arguments)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user