mirror of
https://github.com/BlueWallet/BlueWallet.git
synced 2025-02-22 15:04:50 +01:00
Sanitation and code optimization
This commit is contained in:
parent
2ba890ef88
commit
cf86333464
2 changed files with 4 additions and 4 deletions
2
App.js
2
App.js
|
@ -20,7 +20,7 @@ export default class App extends React.Component {
|
|||
}
|
||||
|
||||
handleOpenURL = event => {
|
||||
if (event.url && event.url.indexOf('bitcoin:') === 0) {
|
||||
if (event.url && event.url.toLowerCase().indexOf('bitcoin:') === 0) {
|
||||
this.navigator &&
|
||||
this.navigator.dispatch(
|
||||
NavigationActions.navigate({
|
||||
|
|
|
@ -75,9 +75,9 @@ export default class SendDetails extends Component {
|
|||
try {
|
||||
parsedBitcoinUri = bip21.decode(props.navigation.state.params.uri);
|
||||
|
||||
address = parsedBitcoinUri.address ? parsedBitcoinUri.address : address;
|
||||
amount = parsedBitcoinUri.options.amount ? parsedBitcoinUri.options.amount : amount;
|
||||
memo = parsedBitcoinUri.options.label ? parsedBitcoinUri.options.label : memo;
|
||||
address = parsedBitcoinUri.address || address;
|
||||
amount = parsedBitcoinUri.options.amount || amount;
|
||||
memo = parsedBitcoinUri.options.label || memo;
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
alert('Error: Unable to decode Bitcoin address');
|
||||
|
|
Loading…
Add table
Reference in a new issue