Check if array is empty
This commit is contained in:
parent
804c37bffa
commit
8c90f6f346
1 changed files with 1 additions and 1 deletions
|
|
@ -24,7 +24,7 @@ angular.module('copayApp.services').factory('txFormatService', function(profileS
|
|||
root.processTx = function(tx) {
|
||||
if (!tx) return;
|
||||
|
||||
if (lodash.isArray(tx.outputs) && tx.action != 'received') {
|
||||
if (lodash.isArray(tx.outputs) && tx.outputs.length > 0 && tx.action != 'received') {
|
||||
tx.hasMultiplesOutputs = true;
|
||||
tx.recipientCount = tx.outputs.length;
|
||||
tx.amount = lodash.reduce(tx.outputs, function(total, o) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue