Skip to content

Commit 38a5f7a

Browse files
committed
Transform error messages
1 parent a15f324 commit 38a5f7a

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

lib/main.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ var minmaxViewBufferIndex = require( '@stdlib/ndarray-base-minmax-view-buffer-in
2525
var ndarray2object = require( '@stdlib/ndarray-base-ndarraylike2object' );
2626
var strides2order = require( '@stdlib/ndarray-base-strides2order' );
2727
var anyIsEntryIn = require( '@stdlib/array-base-assert-any-is-entry-in' );
28-
var format = require( '@stdlib/string-format' );
28+
var format = require( '@stdlib/error-tools-fmtprodmsg' );
2929
var blockedaccessorbinary2d = require( './2d_blocked_accessors.js' );
3030
var blockedaccessorbinary3d = require( './3d_blocked_accessors.js' );
3131
var blockedaccessorbinary4d = require( './4d_blocked_accessors.js' );
@@ -251,7 +251,7 @@ function binary( arrays, fcn ) { // eslint-disable-line max-statements
251251
for ( i = 0; i < ndims; i++ ) {
252252
d = shx[ i ];
253253
if ( d !== shy[ i ] || d !== shz[ i ] ) {
254-
throw new Error( 'invalid arguments. Arrays must have the same shape.' );
254+
throw new Error( format('null0d') );
255255
}
256256
// Note that, if one of the dimensions is `0`, the length will be `0`...
257257
len *= d;

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"@stdlib/ndarray-base-numel": "^0.2.2",
4747
"@stdlib/ndarray-base-strides2order": "^0.2.2",
4848
"@stdlib/ndarray-base-vind2bind": "^0.2.2",
49-
"@stdlib/string-format": "^0.2.2",
49+
"@stdlib/error-tools-fmtprodmsg": "^0.2.2",
5050
"@stdlib/types": "^0.4.3",
5151
"@stdlib/error-tools-fmtprodmsg": "^0.2.2"
5252
},

0 commit comments

Comments
 (0)