Skip to content

Commit 9032249

Browse files
authored
fix: use correct strided index
Signed-off-by: Athan <[email protected]>
1 parent 0f9ea2e commit 9032249

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/node_modules/@stdlib/stats/base/max-by/lib/accessors.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ function maxBy( N, x, strideX, offsetX, clbk, thisArg ) {
6868
get = x.accessors[ 0 ];
6969

7070
if ( N === 1 || strideX === 0 ) {
71-
v = clbk.call( thisArg, get( xbuf, offsetX ), 0, 0, x );
71+
v = clbk.call( thisArg, get( xbuf, offsetX ), 0, offsetX, x );
7272
if ( v === void 0 ) {
7373
return NaN;
7474
}

0 commit comments

Comments
 (0)