miqro 7.3.0 → 7.3.2

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.
File without changes
@@ -47,7 +47,7 @@ export function setupExitHandlers(app) {
47
47
  }
48
48
  process.exit(EXIT_CODES.ABNORMAL_UNCONTROLLED);
49
49
  });
50
- process.on('exit', function (code) {
50
+ process.on('exit', async function (code) {
51
51
  if (exceptionOccured) {
52
52
  app.logger?.error('Exception occured');
53
53
  }
@@ -60,7 +60,7 @@ export function setupExitHandlers(app) {
60
60
  }*/
61
61
  cleanJSX(app);
62
62
  if (app.server) {
63
- app.stop();
63
+ await app.stop();
64
64
  }
65
65
  }
66
66
  });
File without changes
@@ -366,10 +366,10 @@ export class Miqro {
366
366
  this.connect();
367
367
  await this.dbManager.connectAll();
368
368
  this.server = new App({
369
- onUpgrade: (req, socket, head) => {
369
+ onUpgrade: async (req, socket, head) => {
370
370
  try {
371
371
  req.server = this.serverInterface;
372
- return this.webSocketManager.onUpgrade(req, socket, head);
372
+ return await this.webSocketManager.onUpgrade(req, socket, head);
373
373
  }
374
374
  catch (e) {
375
375
  this.logger?.error(e);