Skip to content

Commit 3269817

Browse files
David MaloneyDavid Maloney
authored andcommitted
remove bad truthiness checks
truthy checks were used here, but you'll get an empty hash which will be treated as true causing the test to be invalid and allowing for errors further in the method MSP-9972
1 parent e943cb5 commit 3269817

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/rex/parser/appscan_nokogiri.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,9 +141,9 @@ def parse_params(request_body)
141141

142142
def report_web_page(&block)
143143
return unless(in_issue && has_text)
144-
return unless @state[:web_site]
145-
return unless @state[:response_headers]
146-
return unless @state[:uri]
144+
return unless @state[:web_site].present?
145+
return unless @state[:response_headers].present?
146+
return unless @state[:uri].present?
147147
web_page_info = {}
148148
web_page_info[:web_site] = @state[:web_site]
149149
web_page_info[:path] = @state[:uri].path

0 commit comments

Comments
 (0)