Skip to content

Commit

Permalink
fixes broken tests
Browse files Browse the repository at this point in the history
  • Loading branch information
comountainclimber committed Jul 10, 2018
1 parent 723fa63 commit 24fde2f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion app/modules/generateWallet.js
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,10 @@ export const getEncryptedWIF = (state: Object) => state.generateWallet.encrypted
export const isSaved = (state: Object) => {
const savedAddresses = state.spunky.ACCOUNTS.data
const address = state.generateWallet.address
return Boolean(savedAddresses.find(addressData => addressData.address === address))
if (savedAddresses) {
return Boolean(savedAddresses.find(addressData => addressData.address === address))
}
return false
}

const initialState = {
Expand Down

0 comments on commit 24fde2f

Please sign in to comment.