REF: xpub parameter

This commit is contained in:
Marcos Rodriguez Vélez 2021-09-25 12:05:43 -04:00
parent c0a2d08f2f
commit 5c954213da
2 changed files with 6 additions and 6 deletions

2
App.js
View file

@ -92,7 +92,7 @@ const App = () => {
NavigationService.navigate('WalletXpubRoot', {
screen: 'WalletXpub',
params: {
xPub: data.userInfo.xpub,
xpub: data.userInfo.xpub,
},
});
break;

View file

@ -24,7 +24,7 @@ const styles = StyleSheet.create({
const WalletXpub = () => {
const { wallets } = useContext(BlueStorageContext);
const { walletID, xPub } = useRoute().params;
const { walletID, xpub } = useRoute().params;
const wallet = wallets.find(w => w.getID() === walletID);
const [isLoading, setIsLoading] = useState(true);
const [xPubText, setXPubText] = useState();
@ -48,8 +48,8 @@ const WalletXpub = () => {
setParams({ xPub: wallet.getXpub() });
setXPubText(wallet.getXpub());
setIsLoading(false);
} else if (xPub) {
setXPubText(xPub);
} else if (xpub) {
setXPubText(xpub);
setIsLoading(false);
}
});
@ -58,7 +58,7 @@ const WalletXpub = () => {
Privacy.disableBlur();
};
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [goBack, walletID, xPub]),
}, [goBack, walletID, xpub]),
);
const onLayout = e => {
@ -82,7 +82,7 @@ const WalletXpub = () => {
<BlueSpacing20 />
</>
)}
<QRCodeComponent value={xPub} size={qrCodeSize} />
<QRCodeComponent value={xpub} size={qrCodeSize} />
<BlueSpacing20 />
<BlueCopyTextToClipboard text={xPubText} />