We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7d340f2 commit 72d1412Copy full SHA for 72d1412
lib/node_modules/@stdlib/stats/base/min-by/lib/accessors.js
@@ -68,15 +68,15 @@ function minBy( N, x, strideX, offsetX, clbk, thisArg ) {
68
get = x.accessors[ 0 ];
69
70
if ( N === 1 || strideX === 0 ) {
71
- v = clbk.call( thisArg, get( xbuf, offsetX ), 0, offsetX, x );
+ v = clbk.call( thisArg, get( xbuf, offsetX ), 0, offsetX, xbuf );
72
if ( v === void 0 ) {
73
return NaN;
74
}
75
return v;
76
77
ix = offsetX;
78
for ( i = 0; i < N; i++ ) {
79
- min = clbk.call( thisArg, get( xbuf, ix ), i, ix, x );
+ min = clbk.call( thisArg, get( xbuf, ix ), i, ix, xbuf );
80
if ( min !== void 0 ) {
81
break;
82
@@ -88,7 +88,7 @@ function minBy( N, x, strideX, offsetX, clbk, thisArg ) {
88
i += 1;
89
for ( i; i < N; i++ ) {
90
ix += strideX;
91
- v = clbk.call( thisArg, get( xbuf, ix ), i, ix, x );
+ v = clbk.call( thisArg, get( xbuf, ix ), i, ix, xbuf );
92
93
continue;
94
0 commit comments