diff --git a/src/random/draw.ts b/src/random/draw.ts index 2c78783c..27e0ded3 100644 --- a/src/random/draw.ts +++ b/src/random/draw.ts @@ -15,6 +15,9 @@ import { random } from 'radashi' * // => [1, 2, 3] * ``` */ +export function draw(array: readonly []): null +export function draw(array: readonly T[]): T + export function draw(array: readonly T[]): T | null { const max = array.length if (max === 0) {