Skip to content

Commit 87a1565

Browse files
committed
[fix] not operator has single term which goes last
1 parent 87310bb commit 87a1565

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/riemann-query.coffee

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,9 @@ js_ast = (ast) ->
224224
else
225225
[node_type, terms...] = ast
226226

227+
switch node_type
228+
when "!" then terms = (list null, (first terms))
229+
227230
(join " ", (list "(",
228231
(js_ast (first terms)),
229232
(node_type),

0 commit comments

Comments
 (0)