@nxtedition/shared 2.0.5 → 2.0.6

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.
Files changed (2) hide show
  1. package/index.js +1 -4
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -44,10 +44,7 @@ async function* _reader({ sharedState, sharedBuffer }, cb) {
44
44
  readPos += len
45
45
 
46
46
  if (cb) {
47
- const thenable = cb(raw)
48
- if (typeof thenable?.then === 'function') {
49
- await thenable
50
- }
47
+ await cb(raw)
51
48
  } else {
52
49
  yield raw
53
50
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nxtedition/shared",
3
- "version": "2.0.5",
3
+ "version": "2.0.6",
4
4
  "description": "Ring Buffer for NodeJS cross Worker communication",
5
5
  "main": "index.js",
6
6
  "repository": {