Skip to content

Commit a15433e

Browse files
authored
fix: check for api.query.identity in getSubIdentities (#6093)
1 parent 1996dd4 commit a15433e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/api-derive/src/accounts/identity.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ export function identity (instanceId: string, api: DeriveApi): (accountId?: Acco
148148
function getSubIdentities (identity: DeriveAccountRegistration, api: DeriveApi, accountId?: AccountId | Uint8Array | string): Observable<DeriveAccountRegistration> {
149149
const targetAccount = identity.parent || accountId;
150150

151-
if (!targetAccount) {
151+
if (!targetAccount || !api.query.identity) {
152152
// No valid accountId return the identity as-is
153153
return of(identity);
154154
}

0 commit comments

Comments
 (0)