Repository navigation
fix(wallet): consume real sdk 0.13.3, show display_name for Bloque Friends - #69
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
getAliasDisplayNameonly readmetadata.name, which never gets populated anywhere in the backend — the sender saw their own alias repeated instead of a name, defeating the verification purpose of the screen.@bloque/sdk-identity@0.13.3(published this session) now typesdisplay_name, derived server-side from the recipient's KYC profile (identities.profile), and the backend (payment-rails#980, merged) already serves it.details/metadatain theGET /api/aliasesresponse (strict allowlist). The SDK'sAliasResponsetype still declares both as required, so the oldmetadata.name/metadata.aliasfallback would have thrown at runtime (Cannot read properties of undefined) the next time this screen ran — fixed here before it shipped, not found in production.How it works
getAliasDisplayNamenow returnsdisplay_namewhen present (trimmed, non-empty), falling back straight to the rawaliasstring — no moremetadataaccess. Everything else in the Bloque Friends flow (account_urn resolution, transfer) is unchanged; this PR is purely the SDK version bump plus the one display function.Changes
package.json—@bloque/sdk,@bloque/sdk-accounts,@bloque/sdk-identity,@bloque/sdk-swap(deps) and theoverridesblock (accounts/compliance/core/identity/orgs/swap) bumped0.13.2→0.13.3.bun.lock— regenerated.src/routes/_authed/send/bloque-friends/index.tsx—getAliasDisplayName: drop themetadata.name/metadata.aliasreads (field no longer sent by the backend), preferdisplay_name, fall back toalias.Dev requirements
None — no new setup required.
@bloque/sdk-identity@0.13.3is already published on npm.Risk
.metadata/.detailsoff anAliasresult (checked).AliasResponse) still declaresdetails/metadataas required even though the backend stopped sending them — a latent type/runtime mismatch upstream in the SDK package itself, not fixed here (out of scope for this PR, worth its own follow-up in thesdkrepo).Linear: https://linear.app/bloque/issue/BQE-2635/bloque-friends-transfer-siempre-falla-alias-resuelve-a-identity-urn