@jaypie/express 1.2.4-rc17 → 1.2.4-rc19

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/dist/esm/index.js CHANGED
@@ -1536,6 +1536,8 @@ function safeSendJson(res, statusCode, data) {
1536
1536
  if (res._resolve) {
1537
1537
  res._resolve(res.buildResult());
1538
1538
  }
1539
+ // Emit "finish" event so runExpressApp's promise resolves
1540
+ res.emit("finish");
1539
1541
  return;
1540
1542
  }
1541
1543
  // Fall back to standard Express methods for real responses
@@ -1559,6 +1561,8 @@ function safeSend(res, statusCode, body) {
1559
1561
  if (res._resolve) {
1560
1562
  res._resolve(res.buildResult());
1561
1563
  }
1564
+ // Emit "finish" event so runExpressApp's promise resolves
1565
+ res.emit("finish");
1562
1566
  return;
1563
1567
  }
1564
1568
  // Fall back to standard Express methods for real responses