From 1592b127be54acc22295d0b1e0d8d38d8e6ddfaa Mon Sep 17 00:00:00 2001 From: Cafe137 Date: Tue, 18 Jun 2024 13:49:53 +0200 Subject: [PATCH] fix: ignore errors while waiting for stamp --- src/bee.ts | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/bee.ts b/src/bee.ts index 603a78b8..589f1522 100644 --- a/src/bee.ts +++ b/src/bee.ts @@ -1810,7 +1810,7 @@ export class Bee { } private async waitForUsablePostageStamp(id: BatchId, timeout = 240_000): Promise { - const TIME_STEP = 2_000 + const TIME_STEP = 3_000 for (let time = 0; time < timeout; time += TIME_STEP) { try { const stamp = await this.getPostageBatch(id) @@ -1818,13 +1818,7 @@ export class Bee { if (stamp.usable) { return } - } catch (error: any) { - const message = error?.response?.data?.message || error?.message || '' - - if (!message.includes('batch not usable')) { - throw error - } - } + } catch (error: any) {} await System.sleepMillis(TIME_STEP) }