Skip to content

Commit

Permalink
Ensure encoding error is handled
Browse files Browse the repository at this point in the history
  • Loading branch information
taylorbrooks committed Jun 4, 2024
1 parent 8c458a4 commit 220f2ca
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/rock_rms/error.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def on_complete(env)
private

def html_body?(body)
body.start_with?('<!DOCTYPE html>')
body.lstrip.start_with?('<!DOCTYPE html>')
end

def check_html_error(env)
Expand Down
2 changes: 1 addition & 1 deletion spec/rock_rms/fixtures/html_error.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<!DOCTYPE html>
<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
Expand Down

0 comments on commit 220f2ca

Please sign in to comment.