Skip to content

Commit 63444e6

Browse files
committed
Transform error messages
1 parent 926078a commit 63444e6

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

lib/main.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222

2323
var isCollection = require( '@stdlib/assert-is-collection' );
2424
var isFunction = require( '@stdlib/assert-is-function' );
25-
var format = require( '@stdlib/string-format' );
25+
var format = require( '@stdlib/error-tools-fmtprodmsg' );
2626

2727

2828
// MAIN //
@@ -59,10 +59,10 @@ function inmap( collection, fcn, thisArg ) {
5959
var v;
6060
var i;
6161
if ( !isCollection( collection ) ) {
62-
throw new TypeError( format( 'invalid argument. First argument must be a collection. Value: `%s`.', collection ) );
62+
throw new TypeError( format( '1UzAh', collection ) );
6363
}
6464
if ( !isFunction( fcn ) ) {
65-
throw new TypeError( format( 'invalid argument. Second argument must be a function. Value: `%s`.', fcn ) );
65+
throw new TypeError( format( '1Uz2H', fcn ) );
6666
}
6767
len = collection.length;
6868
for ( i = 0; i < len; i++ ) {

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
"dependencies": {
4040
"@stdlib/assert-is-collection": "^0.2.2",
4141
"@stdlib/assert-is-function": "^0.2.2",
42-
"@stdlib/string-format": "^0.2.2",
42+
"@stdlib/error-tools-fmtprodmsg": "^0.2.2",
4343
"@stdlib/types": "^0.4.3",
4444
"@stdlib/error-tools-fmtprodmsg": "^0.2.2"
4545
},

0 commit comments

Comments
 (0)