feat(sdk): expose require user presence config#236
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: db61d81005
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| rp_context: RpContextWasm, | ||
| action_description?: string, | ||
| bridge_url?: string, | ||
| require_user_presence?: boolean, |
There was a problem hiding this comment.
Make require_user_presence required in TS session signatures
createSession/proveSession are declared with require_user_presence as optional here, but the exported Rust functions take a plain bool argument. That means callers can write code that type-checks while omitting this value (or shifting later optional args into this slot), and the wasm-bindgen boundary will receive a non-boolean/undefined for a required boolean parameter, causing runtime failures before the request is created. Align the declaration with runtime behavior by making this parameter required (or make the Rust side Option<bool> with an explicit default).
Useful? React with 👍 / 👎.
This PR ...
require_user_presenceto JS request and session configsuser_presence_failedfrom JS native transport when required completion is missing or falseStacked on #230.