Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Remove special cased OutputProcessor#process_call

There should never be the case where the target of a :call Sexp is a
symbol, it should always be either `nil` or a Sexp. Brakeman should not
be building invalid Sexps.
  • Loading branch information...
commit c0cedbd129776157a20cd8b78a08e28b94a1cb3f 1 parent ef8ea3f
@presidentbeef authored
Showing with 0 additions and 30 deletions.
  1. +0 −30 lib/brakeman/processors/output_processor.rb
View
30 lib/brakeman/processors/output_processor.rb
@@ -23,36 +23,6 @@ def process exp
end
end
- def process_call exp
- if exp[0].is_a? Symbol
- target = exp[0]
-
- method = exp[1]
-
- args = process exp[2]
-
- out = nil
-
- if method == :[]
- if target
- out = "#{target}[#{args}]"
- else
- raise Exception.new("Not sure what to do with access and no target: #{exp}")
- end
- else
- if target
- out = "#{target}.#{method}(#{args})"
- else
- out = "#{method}(#{args})"
- end
- end
- exp.clear
- out
- else
- super exp
- end
- end
-
def process_lvar exp
out = "(local #{exp[0]})"
exp.clear
Please sign in to comment.
Something went wrong with that request. Please try again.