Update components/CompanionDelegates.tsx

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
This commit is contained in:
Marcos Rodriguez Vélez 2024-11-18 02:43:18 -04:00 committed by GitHub
parent f8b2db33cc
commit 823e63bf75
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -208,15 +208,23 @@ const CompanionDelegates = () => {
console.error('Error detecting QR code:', error); console.error('Error detecting QR code:', error);
} }
} else { } else {
triggerHapticFeedback(HapticFeedbackTypes.NotificationSuccess);
DeeplinkSchemaMatch.navigationRouteFor(event, (value: [string, any]) => navigationRef.navigate(...value), { DeeplinkSchemaMatch.navigationRouteFor(event, (value: [string, any]) => navigationRef.navigate(...value), {
wallets, wallets,
addWallet, addWallet,
saveToDisk, saveToDisk,
setSharedCosigner, setSharedCosigner,
})
.then(() => {
triggerHapticFeedback(HapticFeedbackTypes.NotificationSuccess);
})
.catch(error => {
console.error('Error processing URL:', error);
triggerHapticFeedback(HapticFeedbackTypes.NotificationError);
presentAlert({ message: loc.send.invalid_url });
}); });
} }
} }
}
}, },
[wallets, addWallet, saveToDisk, setSharedCosigner], [wallets, addWallet, saveToDisk, setSharedCosigner],
); );