diff --git a/src/classes/Bot.ts b/src/classes/Bot.ts index 7e1683ed0..b20e53493 100644 --- a/src/classes/Bot.ts +++ b/src/classes/Bot.ts @@ -959,7 +959,7 @@ export default class Bot { promise .then(() => { - this.manager.pollInterval = 60 * 1000; + this.manager.pollInterval = 5 * 1000; this.setReady = true; this.handler.onReady(); this.manager.doPoll(); diff --git a/src/classes/Commands/sub-classes/Manager.ts b/src/classes/Commands/sub-classes/Manager.ts index 86ad516b5..265022c4c 100644 --- a/src/classes/Commands/sub-classes/Manager.ts +++ b/src/classes/Commands/sub-classes/Manager.ts @@ -931,7 +931,7 @@ export default class ManagerCommands { // Bring back online this.bot.client.setPersona(EPersonaState.Online); this.bot.handler.isUpdatingStatus = false; - this.bot.manager.pollInterval = 60 * 1000; + this.bot.manager.pollInterval = 5 * 1000; }; try { diff --git a/src/classes/Trades.ts b/src/classes/Trades.ts index 35c8c5417..612332845 100644 --- a/src/classes/Trades.ts +++ b/src/classes/Trades.ts @@ -139,7 +139,10 @@ export default class Trades { const activeReceived = received.filter(offer => offer.state === TradeOfferManager.ETradeOfferState['Active']); const activeReceivedCount = activeReceived.length; - if (filter === TradeOfferManager.EOfferFilter['ActiveOnly'] && this.pollCount / 5 >= 1) { + if ( + filter === TradeOfferManager.EOfferFilter['ActiveOnly'] && + (this.pollCount * this.bot.manager.pollInterval) / (2 * 5 * 60 * 1000) >= 1 + ) { this.pollCount = 0; const activeSent = sent.filter(offer => offer.state === TradeOfferManager.ETradeOfferState['Active']);