mirror of
https://github.com/github/codeql.git
synced 2026-04-18 05:24:01 +02:00
The `send()` example is not flagged by any current query, so it was weird talking about it as "vulnerable".
10 lines
232 B
Ruby
10 lines
232 B
Ruby
module Invoker
|
|
def attach(klass, name, target)
|
|
var = :"@@#{name}"
|
|
klass.class_variable_set(var, target)
|
|
klass.define_method(name) do |*args|
|
|
self.class.class_variable_get(var).send(name, *args)
|
|
end
|
|
end
|
|
end
|