Skip to content

Commit

Permalink
GetPredictionErr does not use scannerTools field #2
Browse files Browse the repository at this point in the history
  • Loading branch information
DmitriiKh committed Aug 31, 2020
1 parent 3d3c46e commit 2db1c8b
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions CarefulAudioRepair/Data/Channel - Copy.cs
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,14 @@ public Patch[] GetAllPatches()
/// </summary>
/// <param name="position">Position of prediction error.</param>
/// <returns>Value.</returns>
public double GetPredictionErr(int position) =>
this.scannerTools.PredictionErrPatcher.GetValue(position);
public double GetPredictionErr(int position)
{
var tools = new ScannerTools(this.inputImmutable, this.settings);
var predictionErr = tools.PredictionErrPatcher.GetValue(position);
tools.Dispose();

return predictionErr;
}

/// <inheritdoc/>
public void Dispose()
Expand Down

0 comments on commit 2db1c8b

Please sign in to comment.