Browse Source

Any type of args allowed

m-2k 8 years ago
parent
commit
cebdc55b6a
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/actions/action_jq.erl

+ 1 - 1
src/actions/action_jq.erl

@@ -11,7 +11,7 @@
 
 render_action(#jq{property=?U,target=T,method=Methods,args=Args0,format=F}) ->
     Args = case F of "'~s'" -> [ ?R(Args0) ]; _ -> Args0 end,
-    Format = fun(A) when is_tuple(A) orelse is_integer(A) -> ?R(A); (A) -> A end,
+    Format = fun(A) when is_tuple(A) orelse is_integer(A) -> ?R(A); (A) -> nitro:to_list(A) end,
     RenderedArgs = string:join([ Format(A) || A <- Args], ","),
     [[?T(T),".",?B(M),"(",nitro:f(F,[RenderedArgs]),");"] || M <- Methods];
 render_action(#jq{target=T,method=?U,property=P,right=R,args=simple}) -> [?B(T),".",?B(P),"='",?R(R),"';"];