func Export(r render.Render, req *http.Request, zc *zk.Conn) { path := req.URL.Query().Get("path") if path == "" { path = "/" } pathValues, err := zc.Export(path) if err != nil { r.JSON(500, false) } else { r.JSON(200, pathValues) } }