From 1940e8f4202867044d1c79e9d0060da270589f2d Mon Sep 17 00:00:00 2001 From: Serge Alex Date: Mon, 2 Nov 2026 07:56:40 +0300 Subject: [PATCH] feat-safe-fetch-hook-for-stream-detection --- injected/chat-logger.js | 1 + 1 file changed, 1 insertion(+) diff --git a/injected/chat-logger.js b/injected/chat-logger.js index dbe8018..7b05000 100644 --- a/injected/chat-logger.js +++ b/injected/chat-logger.js @@ -216,6 +216,7 @@ }) } + try { var __ofF1 = window.fetch; window.fetch = function (u, o) { try { var __us1 = (typeof u === 'string') ? u : ((u && u.url) ? String(u.url) : ''); if (__us1.indexOf('chat/completion') !== -1) { fetchTotal = fetchTotal + 1 } } catch (e) { } return __ofF1.apply(this, arguments) } } catch (e) { } var origOpen = XMLHttpRequest.prototype.open var origSend = XMLHttpRequest.prototype.send XMLHttpRequest.prototype.open = function (m, u) {