Skip to content

Commit

Permalink
Test response @Body as well as response.body
Browse files Browse the repository at this point in the history
  • Loading branch information
jshraibman-mdsol committed Sep 9, 2013
1 parent 3c8a63a commit 87fda02
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/query_reviewer/controller_extensions.rb
Expand Up @@ -39,7 +39,8 @@ def add_query_output_to_view(total_time)
end
end
else
if response.body.is_a?(String) && response.body.match(/<\/body>/i)
if !response.instance_eval{ @body.is_a?(File) || @body.is_a?(Enumerator) } &&
response.body.is_a?(String) && response.body.match(/<\/body>/i)
idx = (response.body =~ /<\/body>/i)
html = query_review_output(false, total_time)
response.body = response.body.insert(idx, html)
Expand Down

0 comments on commit 87fda02

Please sign in to comment.