Commit 3e49fcc
committed
docs(function): propagate unenrollMfa boolean in example snippets
Address Copilot review on 979a5b0: `Client.unenrollMfa()` returns
`Promise<boolean>`, but both new examples discarded the result and
returned `{ success: true }` unconditionally. That breaks the
convention established by `deleteUser` / `sendPasswordResetEmail`
elsewhere in this guide and would mask a false return from the API.
- Single-factor example now captures and returns the boolean
(`const success = await idpClient.unenrollMfa(...); return { success }`).
- Reset-all example collects the per-factor booleans via
`Promise.all` and aggregates with `results.every(Boolean)`.1 parent 979a5b0 commit 3e49fcc
1 file changed
Lines changed: 7 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
346 | 346 | | |
347 | 347 | | |
348 | 348 | | |
349 | | - | |
350 | | - | |
| 349 | + | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
351 | 354 | | |
352 | 355 | | |
353 | 356 | | |
| |||
362 | 365 | | |
363 | 366 | | |
364 | 367 | | |
365 | | - | |
| 368 | + | |
366 | 369 | | |
367 | 370 | | |
368 | 371 | | |
369 | 372 | | |
370 | 373 | | |
371 | | - | |
| 374 | + | |
372 | 375 | | |
373 | 376 | | |
374 | 377 | | |
| |||
0 commit comments