@yopdev/dev-server 2.0.1 → 2.0.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.
@@ -51,7 +51,7 @@ class EventsProxy {
51
51
  this.LOGGER.warn('no handlers found for message %o', message);
52
52
  }
53
53
  const record = this.mapper(message);
54
- handlers.forEach((handler) => handler
54
+ return Promise.all(handlers.map((handler) => handler
55
55
  .handler({ Records: [record] })
56
56
  .then(() => {
57
57
  this.LOGGER.debug('handler %s accepted message', handler.name);
@@ -59,7 +59,7 @@ class EventsProxy {
59
59
  .catch((e) => {
60
60
  const error = this.extractErrorMessage(e);
61
61
  this.LOGGER.error(e, 'handler %s failed with %s', handler.name, error);
62
- }));
62
+ }))).then(() => undefined);
63
63
  };
64
64
  this.stop = async () => (0, stoppable_1.stopConsumer)(this.pollingFrequency, this.consumer);
65
65
  this.LOGGER = logging_1.LoggerFactory.create(`SNS->SQS[${name}]`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yopdev/dev-server",
3
- "version": "2.0.1",
3
+ "version": "2.0.2",
4
4
  "scripts": {
5
5
  "compile": "tsc",
6
6
  "pretest": "npm run compile",