lib/quick_script/interaction.rb in quick_script-0.11.11 vs lib/quick_script/interaction.rb in quick_script-0.12.0
- old
+ new
@@ -18,10 +18,10 @@
def method_missing(method_sym, *args, &block)
@names[method_sym] = block
end
end
- def json_resp(data, meta, opts = {})
+ def json_resp(data, meta=true, opts = {})
meta = 200 if meta == true
meta = 404 if meta == false
opts[:data] = data
opts[:meta] = meta
opts.to_json