# File lib/brakeman/processors/lib/call_conversion_helper.rb, line 23 def join_strings lhs, rhs, original_exp = nil if string? lhs and string? rhs result = Sexp.new(:str).line(lhs.line) result.value = lhs.value + rhs.value if result.value.length > 50 # Avoid gigantic strings lhs else result end elsif call? lhs and lhs.method == :+ and string? lhs.first_arg and string? rhs joined = join_strings lhs.first_arg, rhs lhs.first_arg = joined lhs elsif safe_literal? lhs or safe_literal? rhs safe_literal(lhs.line) else original_exp end end