Skip to content

Commit

Permalink
style(conf_loader): add "jo" option for ngx.re.sub
Browse files Browse the repository at this point in the history
  • Loading branch information
chronolaw committed Jun 6, 2024
1 parent 4adb677 commit 2f88f09
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kong/conf_loader/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ local function load_config(thing)
-- remove trailing comment, if any
-- and remove escape chars from octothorpes
if value then
value = ngx.re.sub(value, [[\s*(?<!\\)#.*$]], "")
value = ngx.re.sub(value, [[\s*(?<!\\)#.*$]], "", "jo")
value = gsub(value, "\\#", "#")
end
return value
Expand Down

0 comments on commit 2f88f09

Please sign in to comment.