docs(signal): clarify link completion boundary

This commit is contained in:
jesse-merhi
2026-08-12 13:58:12 +10:00
parent 182ec8f837
commit 4b9e9fa2cc
2 changed files with 3 additions and 3 deletions
@@ -239,7 +239,7 @@ describe("linkSignalCliAccount", () => {
});
});
it("preserves a successful link when QR presentation cancels the settling process", async () => {
it("trusts the terminal account marker when presentation cancels process exit", async () => {
const command = createDeferredCommand();
let rejectPresentation!: (error: Error) => void;
const presentation = new Promise<void>((_resolve, reject) => {
+2 -2
View File
@@ -160,8 +160,8 @@ export async function linkSignalCliAccount(params: {
await displayPromise;
if (associatedAccount) {
// signal-cli prints the account only after finishDeviceLink succeeds. A late client
// cancellation must not turn that durable success into a second linking attempt.
// signal-cli emits this marker only after finishDeviceLink returns. The linked account is
// therefore durable even when a late presentation failure terminates the settling process.
return { ok: true, associatedAccount };
}
if (result.code === 0 && result.termination === "exit") {