Skip to content

Commit

Permalink
refactor(dsp): update type usage
Browse files Browse the repository at this point in the history
  • Loading branch information
postspectacular committed Apr 19, 2024
1 parent 27fdbef commit 86be0c3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/dsp/src/fft.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { FnN3, NumericArray } from "@thi.ng/api";
import type { FnN3, Maybe, NumericArray } from "@thi.ng/api";
import type { ComplexArray } from "./api.js";
import { isComplex } from "./complex.js";
import { magDb } from "./convert.js";
Expand Down Expand Up @@ -214,7 +214,7 @@ export const fft = (
complex: NumericArray | ComplexArray,
window?: NumericArray
): ComplexArray => {
let real: NumericArray, img: NumericArray | undefined;
let real: NumericArray, img: Maybe<NumericArray>;
if (isComplex(complex)) {
real = complex[0];
img = <NumericArray>complex[1];
Expand Down

0 comments on commit 86be0c3

Please sign in to comment.