From d9502fa9b375a9a72f7155115566cb9cea4048c7 Mon Sep 17 00:00:00 2001 From: Siddharth VP Date: Sun, 8 Nov 2020 19:52:53 +0530 Subject: [PATCH] continuedQueryGen: fix bug --- build/bot.js | 3 +++ package.json | 2 +- src/bot.ts | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/build/bot.js b/build/bot.js index 98660b3..357efd0 100644 --- a/build/bot.js +++ b/build/bot.js @@ -1282,6 +1282,9 @@ class mwn { response = await this.request(merge(query, response.continue)); yield response; } + else { + break; + } } } /** diff --git a/package.json b/package.json index 257f2c3..821f7ea 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "mwn", - "version": "0.8.1", + "version": "0.8.2", "description": "MediaWiki bot framework for Node.js", "main": "./build/bot.js", "types": "./build/bot.d.ts", diff --git a/src/bot.ts b/src/bot.ts index d3be63a..ca08a79 100644 --- a/src/bot.ts +++ b/src/bot.ts @@ -1756,6 +1756,8 @@ export class mwn { if (response.continue) { response = await this.request(merge(query, response.continue)); yield response; + } else { + break; } } }