From 56a9a1ccf764ff7a6af8f8a2292cb07443cb4aa7 Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Thu, 28 May 2026 18:19:57 +0000
Subject: [PATCH] =New Gitbit setpu

---
 assets/js/concise/Queue.js |   11 +++++++++--
 1 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/assets/js/concise/Queue.js b/assets/js/concise/Queue.js
index a2232ca..77e5aeb 100644
--- a/assets/js/concise/Queue.js
+++ b/assets/js/concise/Queue.js
@@ -626,7 +626,7 @@
 				if (result.id && operation.id !== result.id) {
 					operation = await this.handleServerMerge(operation, result);
 				} else {
-					operation.status = result.status??'failed';
+					operation.status = result.status??'pending';
 					operation.serverData = result;
 					this.updateOperationStatus(operation.id, operation.status);
 				}
@@ -786,7 +786,14 @@
 		try {
 			this.ui.refresh.button.classList.add('fetching');
 			this.store.clearCache();
-			await this.store.fetch();
+			let response = await this.store.fetch();
+			if (response.status === 429) {
+				console.log('Too many requests. Waiting 30 seconds');
+				this.stopPolling();
+				this.startCountdown(30, () => this.runPollCycle());
+				return;
+			}
+
 			this.ui.refresh.button.classList.remove('fetching');
 			if (!this.maybeStartPolling()) {
 				this.stopPolling();

--
Gitblit v1.10.0