Browse Source

Merge pull request #745 from LN-Zap/fix/pay-onchain

fix(pay): dont focus on value input
renovate/lint-staged-8.x
Tom Kirkpatrick 6 years ago
committed by GitHub
parent
commit
7ac9d7c122
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 6
      app/components/Form/Pay.js

6
app/components/Form/Pay.js

@ -14,17 +14,11 @@ import styles from './Pay.scss'
class Pay extends Component {
componentDidUpdate(prevProps) {
const {
isOnchain,
isLn,
payform: { payInput },
fetchInvoice
} = this.props
// If on-chain, focus on amount to let user know it's editable
if (isOnchain) {
this.amountInput.focus()
}
// If LN go retrieve invoice details
if (prevProps.payform.payInput !== payInput && isLn) {
fetchInvoice(payInput)

Loading…
Cancel
Save