提交 41360798 编写于 作者: J Justin Collins

Fix call indexing of attribute assignment call chains

上级 2c364c39
......@@ -96,7 +96,7 @@ class Brakeman::FindAllCalls < Brakeman::BaseProcessor
#Returns method chain as an array
#For example, User.human.alive.all would return [:User, :human, :alive, :all]
def get_chain call
if call? call
if sexp? call and (call.node_type == :call or call.node_type == :attrasgn)
get_chain(call[1]) + [call[2]]
else
[get_target(call)]
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册