Skip to content

Commit 56f04bd

Browse files
committed
Fix example and descriptions
1 parent b18c30c commit 56f04bd

File tree

4 files changed

+5
-10
lines changed

4 files changed

+5
-10
lines changed

lib/node_modules/@stdlib/string/repeat/README.md

+2-7
Original file line numberDiff line numberDiff line change
@@ -56,17 +56,12 @@ str = repeat( 'beep', 0 );
5656
<!-- eslint no-undef: "error" -->
5757

5858
```javascript
59-
var round = require( '@stdlib/math/base/special/round' );
60-
var randu = require( '@stdlib/random/base/randu' );
59+
var discreteUniform = require( '@stdlib/random/base/discrete-uniform' );
6160
var repeat = require( '@stdlib/string/repeat' );
6261

63-
var str = 'beep';
64-
var n;
6562
var i;
66-
6763
for ( i = 0; i < 100; i++ ) {
68-
n = round( randu()*3.0 );
69-
console.log( repeat( str, n ) );
64+
console.log( repeat( 'beep', discreteUniform( 0, 3 ) ) );
7065
}
7166
```
7267

lib/node_modules/@stdlib/string/repeat/test/test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ tape( 'the main export is a wrapper around a builtin if an environment supports
5151
t.end();
5252
});
5353

54-
tape( 'if the first argument is not a string primitive, the function will throw an error', function test( t ) {
54+
tape( 'if the first argument is not a string, the function will throw an error', function test( t ) {
5555
var values;
5656
var i;
5757

lib/node_modules/@stdlib/string/repeat/test/test.main.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ tape( 'main export is a function', opts, function test( t ) {
4040
t.end();
4141
});
4242

43-
tape( 'if the first argument is not a string primitive, the function will throw an error', opts, function test( t ) {
43+
tape( 'if the first argument is not a string, the function will throw an error', opts, function test( t ) {
4444
var values;
4545
var i;
4646

lib/node_modules/@stdlib/string/repeat/test/test.polyfill.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ tape( 'main export is a function', function test( t ) {
3232
t.end();
3333
});
3434

35-
tape( 'if the first argument is not a string primitive, the function will throw an error', function test( t ) {
35+
tape( 'if the first argument is not a string, the function will throw an error', function test( t ) {
3636
var values;
3737
var i;
3838

0 commit comments

Comments
 (0)