tone 15.2.0 → 15.2.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.
@@ -373,7 +373,9 @@ export class Context extends BaseContext {
373
373
  const workletPromise = this.rawContext.audioWorklet.addModule(url);
374
374
 
375
375
  this._workletPromises.add(workletPromise);
376
- workletPromise.finally(() => this._workletPromises.delete(workletPromise));
376
+ workletPromise.finally(() =>
377
+ this._workletPromises.delete(workletPromise)
378
+ );
377
379
 
378
380
  return workletPromise;
379
381
  }
@@ -561,9 +563,11 @@ export class Context extends BaseContext {
561
563
  private _timeoutLoop(): void {
562
564
  const now = this.now();
563
565
  this._timeouts.forEachBefore(now, (event) => {
564
- // invoke the callback
565
- event.callback();
566
- this._timeouts.remove(event);
566
+ try {
567
+ event.callback();
568
+ } finally {
569
+ this._timeouts.remove(event);
570
+ }
567
571
  });
568
572
  }
569
573
 
package/Tone/version.ts CHANGED
@@ -1 +1 @@
1
- export const version: string = "15.2.0";
1
+ export const version: string = "15.2.1";