Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
render() {
const { doc, onToggle, onChangeDoc, accountsById, accounts, t } = this.props
if (!hasQueryBeenLoaded(accounts)) {
return
}
const value = doc.value
const docCreditCardAccount = doc.creditCardAccount
? accountsById[doc.creditCardAccount._id]
: null
const docCheckingsAccount = doc.checkingsAccount
? accountsById[doc.checkingsAccount._id]
: null
const creditCardAccount =
docCreditCardAccount || this.getCreditCardDefaultValue()
const checkingsAccount =
docCheckingsAccount || this.getCheckingsDefaultValue()