mirror of
https://github.com/TangentFoxy/lua-htmlparser.git
synced 2025-07-27 18:42:19 +00:00
fix comments stripper (fixes #54)
This commit is contained in:
@@ -41,7 +41,7 @@ local function parse(text,limit) -- {{{
|
||||
local tpl = false
|
||||
|
||||
if not opts.keep_comments then -- Strip (or not) comments {{{
|
||||
text = text:gsub("<!--.--->","") -- Many chances commented code will have syntax errors, that'll lead to parser failures
|
||||
text = text:gsub("<!%-%-.-%-%->","") -- Many chances commented code will have syntax errors, that'll lead to parser failures
|
||||
end -- }}}
|
||||
|
||||
local tpr={}
|
||||
|
Reference in New Issue
Block a user