Skip to content
This repository has been archived by the owner on Jul 6, 2021. It is now read-only.

Commit

Permalink
Fix output error
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanhoel committed Dec 8, 2014
1 parent e6260d6 commit edfbe49
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/rack/livereload/body_processor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def process!(env)
head_elements.each do |head|
head.inner_html = "#{template.result(binding)}\n #{head.inner_html}"
end
@string_body = xmlfragment.to_html
@string_body = xmlfragment.to_s

@content_length = @string_body.bytesize()
@livereload_added = true if head_elements.length > 0
Expand Down
2 changes: 1 addition & 1 deletion spec/rack/livereload/body_processor_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@
let(:page_html) { "<script type='text/template'><head></head></script> <!-- <head></head> --> <xmp><head></head></xmp>" }

it 'should not add the livereload js' do
processed_body.should == "<script type=\"text/template\"><head></head></script> <!-- <head></head> --> <xmp><head></head></xmp>"
processed_body.should == "<script type=\"text/template\">\n <head/>\n</script> <!-- <head></head> --> <xmp>\n <head/>\n</xmp>"
end
end

Expand Down

0 comments on commit edfbe49

Please sign in to comment.