diff --git a/src/ByteBeatNode.js b/src/ByteBeatNode.js index 8790ca7..3325ff8 100644 --- a/src/ByteBeatNode.js +++ b/src/ByteBeatNode.js @@ -53,7 +53,9 @@ class BeatWorkletProcessor extends AudioWorkletProcessor { } process(inputs, outputs, parameters) { - this.byteBeat.process(outputs[0][0].length, outputs[0][0], outputs[0][1]); + if (outputs.length > 0) { + this.byteBeat.process(outputs[0][0].length, outputs[0][0], outputs[0][1]); + } return true; } }