@sveltejs/kit 1.0.0-next.413 → 1.0.0-next.414
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -250,7 +250,8 @@ export async function respond(request, options, state) {
|
|
|
250
250
|
try {
|
|
251
251
|
if (error) return;
|
|
252
252
|
|
|
253
|
-
|
|
253
|
+
// == because it could be undefined (in dev) or null (in build, because of JSON.stringify)
|
|
254
|
+
const node = n == undefined ? n : await options.manifest._.nodes[n]();
|
|
254
255
|
return {
|
|
255
256
|
// TODO return `uses`, so we can reuse server data effectively
|
|
256
257
|
data: await load_server_data({
|
|
@@ -260,7 +261,11 @@ export async function respond(request, options, state) {
|
|
|
260
261
|
/** @type {import('types').JSONObject} */
|
|
261
262
|
const data = {};
|
|
262
263
|
for (let j = 0; j < i; j += 1) {
|
|
263
|
-
|
|
264
|
+
const parent = await promises[j];
|
|
265
|
+
if (!parent || parent instanceof HttpError || 'error' in parent) {
|
|
266
|
+
return data;
|
|
267
|
+
}
|
|
268
|
+
Object.assign(data, parent.data);
|
|
264
269
|
}
|
|
265
270
|
return data;
|
|
266
271
|
}
|