/opt/homebrew/lib/node_modules/nginxbeautifier/nginxbeautifier.js:142
return input.match(catchRegex)[1];
^
TypeError: Cannot read property '1' of null
at extractTextBySeperator (/opt/homebrew/lib/node_modules/nginxbeautifier/nginxbeautifier.js:142:39)
at extractAllPossibleText (/opt/homebrew/lib/node_modules/nginxbeautifier/nginxbeautifier.js:164:29)
at strip_line (/opt/homebrew/lib/node_modules/nginxbeautifier/nginxbeautifier.js:193:35)
at Object.clean_lines (/opt/homebrew/lib/node_modules/nginxbeautifier/nginxbeautifier.js:217:49)
at Object.<anonymous> (/opt/homebrew/lib/node_modules/nginxbeautifier/index.js:235:38)
at Module._compile (node:internal/modules/cjs/loader:1092:14)
at Object.Module._extensions..js (node:internal/modules/cjs/loader:1121:10)
at Module.load (node:internal/modules/cjs/loader:972:32)
at Function.Module._load (node:internal/modules/cjs/loader:813:14)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:76:12)
The workaround is to concatenate the string onto a long line:
When parsing a multiline string like this
nginxbeautifier crashes with a following error:
The workaround is to concatenate the string onto a long line: