Skip to content

Commit

Permalink
Fix readme 4
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitryuk committed Jan 2, 2021
1 parent c671759 commit f0a8276
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ let balancer = new RedisFunctionsBalancer([A, B, C], redisClient);
balancer.setMethods([A, B]);
// ... //
// Get async iterator {done, value}
while ( (foo = await balancer.getAsyncIterator().next()) && !foo.done) {
let iterator = await balancer.getAsyncIterator();

while ( (foo = await iterator.next()) && !foo.done) {
// Your function A|B|C will be here evenly
let method = foo.value;

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "redis-functions-balancer",
"version": "1.0.3",
"version": "1.0.4",
"description": "Balance NodeJs functions with Redis",
"repository": "https://github.com/dmitryuk/RedisFunctionsBalancer",
"main": "index.ts",
Expand Down

0 comments on commit f0a8276

Please sign in to comment.