diff --git a/lib/main.js b/lib/main.js index be0ef10..a71f608 100644 --- a/lib/main.js +++ b/lib/main.js @@ -24,7 +24,7 @@ var isArray = require( '@stdlib/assert-is-array' ); var isCollection = require( '@stdlib/assert-is-collection' ); var isTypedArrayLike = require( '@stdlib/assert-is-typed-array-like' ); var isInteger = require( '@stdlib/assert-is-integer' ); -var format = require( '@stdlib/string-format' ); +var format = require( '@stdlib/error-tools-fmtprodmsg' ); var appendArray = require( './append_array.js' ); var appendObject = require( './append_object.js' ); var appendTypedArray = require( './append_typed_array.js' ); @@ -56,7 +56,7 @@ var appendTypedArray = require( './append_typed_array.js' ); */ function append( collection1, collection2 ) { if ( !isCollection( collection2 ) ) { - throw new TypeError( format( 'invalid argument. Second argument must be an array-like object. Value: `%s`.', collection2 ) ); + throw new TypeError( format( '1Ql2y', collection2 ) ); } if ( isArray( collection1 ) ) { return appendArray( collection1, collection2 ); @@ -75,7 +75,7 @@ function append( collection1, collection2 ) { ) { return appendObject( collection1, collection2 ); } - throw new TypeError( format( 'invalid argument. First argument must be either an array, typed array, or an array-like object. Value: `%s`.', collection1 ) ); + throw new TypeError( format( '1QlAi', collection1 ) ); } diff --git a/package.json b/package.json index e5769bd..a88d9d3 100644 --- a/package.json +++ b/package.json @@ -43,7 +43,7 @@ "@stdlib/assert-is-integer": "^0.2.3", "@stdlib/assert-is-typed-array-like": "^0.2.3", "@stdlib/math-base-special-ceil2": "^0.3.1", - "@stdlib/string-format": "^0.2.3", + "@stdlib/error-tools-fmtprodmsg": "^0.2.3", "@stdlib/types": "^0.5.1", "@stdlib/error-tools-fmtprodmsg": "^0.2.3" },