Skip to content
This repository was archived by the owner on Jul 1, 2024. It is now read-only.

Commit 7aeebab

Browse files
Fix type guard
1 parent 6517899 commit 7aeebab

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/darknet.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@ function isIBufferImage(input: any): input is IBufferImage {
3535
'w' in input &&
3636
'h' in input &&
3737
'c' in input &&
38-
typeof input.b === 'number' &&
38+
typeof input.c === 'number' &&
3939
typeof input.w === 'number' &&
4040
typeof input.h === 'number' &&
41-
input.buffer instanceof Buffer
41+
input.b instanceof Buffer
4242
);
4343
}
4444

0 commit comments

Comments
 (0)