Skip to content

Commit b639a8d

Browse files
update ruby example
Co-authored-by: Nick Rolfe <[email protected]>
1 parent 02f500b commit b639a8d

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
def filterScripTags(html)
2-
oldHtml = "";
3-
while (html != oldHtml)
4-
oldHtml = html;
5-
html = html.gsub(/<script[^>]*>.*<\/script>/m, "");
1+
def filter_script_tags(html)
2+
old_html = ""
3+
while (html != old_html)
4+
old_html = html
5+
html = html.gsub(/<script[^>]*>.*<\/script>/m, "")
66
end
7-
return html;
7+
html
88
end

0 commit comments

Comments
 (0)