Skip to content

Commit

Permalink
Merge pull request #2787 from LiskHQ/2779-fix-desktop-notifications-o…
Browse files Browse the repository at this point in the history
…n-betanet

Fix desktop notifications to work with Lisk Core 3.0 - Closes #2779
  • Loading branch information
slaweet committed Feb 17, 2020
2 parents a42f255 + 33abb18 commit d481fba
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/store/middlewares/account.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,11 +95,10 @@ const checkTransactionsAndUpdateAccount = (store, action) => {
const { transactions, settings: { token } } = state;
const account = getActiveTokenAccount(store.getState());

const txs = action.data.block.transactions || [];
const txs = (action.data.block.transactions || []).map(txAdapter);
const blockContainsRelevantTransaction = txs.filter((transaction) => {
const morphedTx = txAdapter(transaction);
const sender = morphedTx ? morphedTx.senderId : null;
const recipient = morphedTx ? morphedTx.recipientId : null;
const sender = transaction ? transaction.senderId : null;
const recipient = transaction ? transaction.recipientId : null;
return account.address === recipient || account.address === sender;
}).length > 0;

Expand Down

0 comments on commit d481fba

Please sign in to comment.