소스 검색

[ruby/rack-sequel] Use CGI.escape_html (#10077)

For Rage this seems to be faster.
Petrik de Heus 1 주 전
부모
커밋
474485fe30
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      frameworks/Ruby/rack-sequel/hello_world.rb

+ 1 - 1
frameworks/Ruby/rack-sequel/hello_world.rb

@@ -70,7 +70,7 @@ class HelloWorld
       html << <<~"HTML"
       <tr>
         <td>#{fortune.id}</td>
-        <td>#{Rack::Utils.escape_html(fortune.message)}</td>
+        <td>#{CGI.escape_html(fortune.message)}</td>
       </tr>
       HTML
     end