Skip to content

Commit

Permalink
fix: remote logic rules cannot be parsed (#837)
Browse files Browse the repository at this point in the history
  • Loading branch information
HolgerHuo authored Oct 31, 2023
1 parent 261b6e8 commit 8ff476a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion rules/provider/classical_strategy.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,11 @@ func ruleParse(ruleRaw string) (string, string, []string) {
} else if len(item) == 2 {
return item[0], item[1], nil
} else if len(item) > 2 {
return item[0], item[1], item[2:]
if item[0] == "NOT" || item[0] == "OR" || item[0] == "AND" || item[0] == "SUB-RULE" {
return item[0], strings.Join(item[1:len(item)], ","), nil
} else {
return item[0], item[1], item[2:]
}
}

return "", "", nil
Expand Down

0 comments on commit 8ff476a

Please # to comment.