mirror of
https://github.com/0xJacky/nginx-ui.git
synced 2025-05-12 10:55:51 +02:00
enhance: skip the directives validation check of gonginx
This commit is contained in:
parent
99d6983924
commit
1658e4b5a3
6 changed files with 8 additions and 8 deletions
|
@ -11,7 +11,7 @@ func (c *NgxConfig) FmtCode() (fmtContent string) {
|
|||
}
|
||||
|
||||
func FmtCode(content string) (fmtContent string, err error) {
|
||||
p := parser.NewStringParser(content)
|
||||
p := parser.NewStringParser(content, parser.WithSkipValidDirectivesErr())
|
||||
c, err := p.Parse()
|
||||
if err != nil {
|
||||
return
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue