From 46fa32472b47020ec541e71acddb22876a480e3b Mon Sep 17 00:00:00 2001 From: Nikhil Ranjan Date: Mon, 22 Apr 2024 18:20:48 +0400 Subject: [PATCH] Identity fix. Username has been introduced in identity pallet. (#10491) * Identity fix * Identity fix --- .../src/AccountSidebar/RegistrarJudgement.tsx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/react-components/src/AccountSidebar/RegistrarJudgement.tsx b/packages/react-components/src/AccountSidebar/RegistrarJudgement.tsx index fe99ee67a9..523b3202f4 100644 --- a/packages/react-components/src/AccountSidebar/RegistrarJudgement.tsx +++ b/packages/react-components/src/AccountSidebar/RegistrarJudgement.tsx @@ -1,8 +1,9 @@ // Copyright 2017-2024 @polkadot/react-query authors & contributors // SPDX-License-Identifier: Apache-2.0 -import type { Option } from '@polkadot/types'; +import type { Bytes, Option } from '@polkadot/types'; import type { PalletIdentityRegistration } from '@polkadot/types/lookup'; +import type { ITuple } from '@polkadot/types/types'; import type { HexString } from '@polkadot/util/types'; import React, { useEffect, useState } from 'react'; @@ -34,9 +35,9 @@ const JUDGEMENT_ENUM = [ ]; const OPT_ID = { - transform: (optId: Option): HexString | null => + transform: (optId: Option]>>): HexString | null => optId.isSome - ? optId.unwrap().info.hash.toHex() + ? optId.unwrap()[0].info.hash.toHex() : null };