是否有可能在控制器的实例变量中执行 ruby 代码?
例子:
def something
@code = "redirect_to 'https://www.google.com/'"
exec(@code) // And then it would redirect.
end
是否有可能在控制器的实例变量中执行 ruby 代码?
例子:
def something
@code = "redirect_to 'https://www.google.com/'"
exec(@code) // And then it would redirect.
end