diff options
| author | King'ori Maina <[email protected]> | 2026-01-11 18:27:17 +0200 |
|---|---|---|
| committer | GitHub <[email protected]> | 2026-01-11 10:27:17 -0600 |
| commit | c526e2d908f47c59f1667902ba3750c6fc05ed4f (patch) | |
| tree | 8e2a0c963b49d6a07f068f04007de54843b351e0 | |
| parent | bdbbcd8a0c60be5cee7a5206d5727be7e1100edf (diff) | |
| download | opencode-c526e2d908f47c59f1667902ba3750c6fc05ed4f.tar.gz opencode-c526e2d908f47c59f1667902ba3750c6fc05ed4f.zip | |
fix(tui): copy oauth url when no device code (#7812)
| -rw-r--r-- | packages/opencode/src/cli/cmd/tui/component/dialog-provider.tsx | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/packages/opencode/src/cli/cmd/tui/component/dialog-provider.tsx b/packages/opencode/src/cli/cmd/tui/component/dialog-provider.tsx index 8b586fce3..35951c995 100644 --- a/packages/opencode/src/cli/cmd/tui/component/dialog-provider.tsx +++ b/packages/opencode/src/cli/cmd/tui/component/dialog-provider.tsx @@ -112,8 +112,7 @@ function AutoMethod(props: AutoMethodProps) { useKeyboard((evt) => { if (evt.name === "c" && !evt.ctrl && !evt.meta) { - const code = - props.authorization.instructions.match(/[A-Z0-9]{4}-[A-Z0-9]{4}/)?.[0] ?? props.authorization.instructions + const code = props.authorization.instructions.match(/[A-Z0-9]{4}-[A-Z0-9]{4}/)?.[0] ?? props.authorization.url Clipboard.copy(code) .then(() => toast.show({ message: "Copied to clipboard", variant: "info" })) .catch(toast.error) |
