diff --git a/src/KristofferStrube.Blazor.WebAudio/AudioNodes/AudioNode.cs b/src/KristofferStrube.Blazor.WebAudio/AudioNodes/AudioNode.cs index d397176..31d9fba 100644 --- a/src/KristofferStrube.Blazor.WebAudio/AudioNodes/AudioNode.cs +++ b/src/KristofferStrube.Blazor.WebAudio/AudioNodes/AudioNode.cs @@ -59,19 +59,18 @@ protected AudioNode(IJSRuntime jSRuntime, IJSObjectReference jSReference, Creati /// It is possible to connect more than one output to a single with multiple calls to . Thus, "fan-in" is supported.
/// It throws an if is an that has been created using another .
/// It throws an if the is out of bounds.
- /// It throws an if the is out of bounds. + /// It throws an if the is out of bounds.
+ /// It does not return anything even though the specification says that it should return the as chaining is not possible in async code. /// /// The destination parameter is the to connect to. /// The output parameter is an index describing which output of the from which to connect. /// The input parameter is an index describing which input of the destination to connect to. /// /// - /// This method returns destination AudioNode object. - public async Task ConnectAsync(AudioNode destinationNode, ulong output = 0, ulong input = 0) + public async Task ConnectAsync(AudioNode destinationNode, ulong output = 0, ulong input = 0) { IJSObjectReference jSReference = errorHandlingJSReference ?? JSReference; - IJSObjectReference jSInstance = await jSReference.InvokeAsync("connect", destinationNode, output, input); - return await CreateAsync(JSRuntime, jSInstance); + await jSReference.InvokeVoidAsync("connect", destinationNode, output, input); } ///