@plyaz/api 1.8.0 → 1.8.1

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/index.mjs CHANGED
@@ -1163,10 +1163,10 @@ var BatchProcessor = class {
1163
1163
  */
1164
1164
  scheduleFlush() {
1165
1165
  if (this.timer) return;
1166
- this.timer = setImmediate(() => {
1166
+ this.timer = setTimeout(() => {
1167
1167
  this.timer = void 0;
1168
1168
  void this.flush();
1169
- });
1169
+ }, 0);
1170
1170
  }
1171
1171
  /**
1172
1172
  * Flush the current batch
@@ -1198,7 +1198,7 @@ var BatchProcessor = class {
1198
1198
  clear() {
1199
1199
  this.batch.length = 0;
1200
1200
  if (this.timer) {
1201
- clearImmediate(this.timer);
1201
+ clearTimeout(this.timer);
1202
1202
  this.timer = void 0;
1203
1203
  }
1204
1204
  }