From 1dad06646f1affec1576f3b2638818825f24e90d Mon Sep 17 00:00:00 2001 From: netbonus <151201453+netbonus@users.noreply.github.com> Date: Mon, 22 Sep 2025 17:43:11 -0400 Subject: [PATCH] reset data to connect --- src/components/main.tsx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/components/main.tsx b/src/components/main.tsx index 5bd469c..014a666 100644 --- a/src/components/main.tsx +++ b/src/components/main.tsx @@ -240,7 +240,6 @@ class Main extends React.Component { return; } - // CRITICAL: Do not return data if the connection failed if (this.state.keyringConnectionFailed) { console.error(`[KEYRING_RETURN] 🚫 BLOCKED: Connection failed - refusing to return data to consuming library`); console.error(`[KEYRING_RETURN] This prevents consuming library from receiving invalid/stale connection data`); @@ -409,6 +408,12 @@ class Main extends React.Component { showLoading }); + // Reset failure flag at the start of any new connection attempt + if (this.state.openedByKeyring && this.state.keyringConnectionFailed) { + console.log(`[KEYRING_CONNECTION] Resetting keyringConnectionFailed flag for fresh attempt`); + this.setState({ keyringConnectionFailed: false }); + } + // Sanity check -- this should never get hit if (!deviceID || !password) { console.error(`[KEYRING_CONNECTION] Missing credentials - deviceID: ${!!deviceID}, password: ${!!password}`);