lib/metatron/sync_controller.rb in metatron-0.1.9 vs lib/metatron/sync_controller.rb in metatron-0.2.0

- old
+ new

@@ -7,9 +7,11 @@ headers "Access-Control-Allow-Methods" => ["POST"] halt 200 end post "/" do - halt(sync.to_json) + data = sync + data[:children] = data[:children]&.map { |c| c.respond_to?(:render) ? c.render : c } + halt(data.to_json) end end end