diff --git a/components/VC/MosipVCItem/VcItemController.tsx b/components/VC/MosipVCItem/VcItemController.tsx index 6746656d84..496cd0e6e4 100644 --- a/components/VC/MosipVCItem/VcItemController.tsx +++ b/components/VC/MosipVCItem/VcItemController.tsx @@ -37,23 +37,18 @@ export function useVcItemController( const service = useInterpret(machine.current, {devTools: __DEV__}); - let context = useSelector(service, selectContext); - let verifiableCredential = useSelector(service, selectVerifiableCredential); - let emptyWalletBindingId = useSelector(service, selectEmptyWalletBindingId); - let isKebabPopUp = useSelector(service, selectKebabPopUp); + const context = useSelector(service, selectContext); + const verifiableCredential = useSelector(service, selectVerifiableCredential); + const emptyWalletBindingId = useSelector(service, selectEmptyWalletBindingId); + const isKebabPopUp = useSelector(service, selectKebabPopUp); let DISMISS = () => service.send(ExistingMosipVCItemEvents.DISMISS()); let KEBAB_POPUP = () => service.send(ExistingMosipVCItemEvents.KEBAB_POPUP()); const isSavingFailedInIdle = useSelector(service, selectIsSavingFailedInIdle); const storeErrorTranslationPath = 'errors.savingFailed'; - let generatedOn = useSelector(service, selectGeneratedOn); + const generatedOn = useSelector(service, selectGeneratedOn); if (props.vcMetadata.isFromOpenId4VCI()) { - context = useSelector(service, selectContext); - isKebabPopUp = useSelector(service, selectKebabPopUp); - generatedOn = useSelector(service, selectGeneratedOn); - emptyWalletBindingId = useSelector(service, selectEmptyWalletBindingId); DISMISS = () => service.send(EsignetMosipVCItemEvents.DISMISS()); KEBAB_POPUP = () => service.send(EsignetMosipVCItemEvents.KEBAB_POPUP()); - verifiableCredential = useSelector(service, selectVerifiableCredential); } return { service,