From 9bb97b54fe20649becfc091401ce5e00f44720fe Mon Sep 17 00:00:00 2001 From: Agustin Rivera <31522568+eleqtrizit@users.noreply.github.com> Date: Fri, 3 Apr 2026 19:09:14 +0000 Subject: [PATCH] fix(pair): fail fast before qr setup lookup --- extensions/device-pair/index.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/extensions/device-pair/index.ts b/extensions/device-pair/index.ts index 2ed99c31631..caacb6042ce 100644 --- a/extensions/device-pair/index.ts +++ b/extensions/device-pair/index.ts @@ -642,7 +642,7 @@ export default definePluginEntry({ if (authLabelResult.error) { return { text: `Error: ${authLabelResult.error}` }; } - if (!action && isMissingPairingScope(gatewayClientScopes)) { + if ((!action || action === "qr") && isMissingPairingScope(gatewayClientScopes)) { return buildMissingPairingScopeReply(); } @@ -653,9 +653,6 @@ export default definePluginEntry({ const authLabel = authLabelResult.label ?? "auth"; if (action === "qr") { - if (isMissingPairingScope(gatewayClientScopes)) { - return buildMissingPairingScopeReply(); - } const channel = ctx.channel; const target = resolveQrReplyTarget(ctx); let autoNotifyArmed = false;