[SDK] Validate and brand the persisted account did (#11387)
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import {useCallback, useRef, useState} from 'react'
|
||||
import {type TextInput, View} from 'react-native'
|
||||
import {type DidString} from '@atproto/syntax'
|
||||
import {msg} from '@lingui/core/macro'
|
||||
import {useLingui} from '@lingui/react'
|
||||
import {Trans} from '@lingui/react/macro'
|
||||
@@ -126,8 +125,7 @@ function DeleteAccountDialogInner({
|
||||
*/
|
||||
await chatClient.call(chat.bsky.actor.deleteAccount)
|
||||
await client.call(com.atproto.server.deleteAccount, {
|
||||
// the persisted account did is already resolved
|
||||
did: currentAccount.did as DidString,
|
||||
did: currentAccount.did,
|
||||
password,
|
||||
token,
|
||||
})
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
import {useCallback, useState} from 'react'
|
||||
import {View} from 'react-native'
|
||||
import {type DidString} from '@atproto/syntax'
|
||||
import {Trans, useLingui} from '@lingui/react/macro'
|
||||
|
||||
import {saveBytesToDisk} from '#/lib/media/manip'
|
||||
@@ -34,7 +33,7 @@ export function ExportCarDialog({
|
||||
}
|
||||
try {
|
||||
setLoading('repo')
|
||||
const did = currentAccount.did as DidString
|
||||
const did = currentAccount.did
|
||||
const data = await pdsClient.call(com.atproto.sync.getRepo, {did})
|
||||
/*
|
||||
* getRepo declares `application/vnd.ipld.car`, so lex-client hands back
|
||||
|
||||
Reference in New Issue
Block a user