This commit is contained in:
Matias Alejo Garcia 2016-08-31 15:16:00 -03:00
commit 8bc84d397d
No known key found for this signature in database
GPG key ID: 02470DB551277AB3
6 changed files with 21 additions and 13 deletions

View file

@ -35,7 +35,8 @@ angular.module('copayApp.controllers').controller('tabHomeController',
});
walletService.getNotifications(wallet, {
timeSpan: timeSpan
timeSpan: timeSpan,
includeOwn: true,
}, function(err, n) {
if (err) {
console.log('[tab-home.js.35:err:]', $log.error(err)); //TODO

View file

@ -130,7 +130,9 @@ angular.module('copayApp.services')
});
});
wallet.initialize({}, function(err) {
wallet.initialize({
notificationIncludeOwn: true,
}, function(err) {
if (err) {
$log.error('Could not init notifications err:', err);
return;

View file

@ -981,8 +981,15 @@ angular.module('copayApp.services').factory('walletService', function($log, $tim
wallet.getNotifications(opts, function(err, notifications) {
if (err) return cb(err);
var ignored = {
'NewBlock': 1,
'BalanceUpdated': 1,
'NewOutgoingTxByThirdParty': 1,
'NewAddress': 1,
};
notifications = lodash.filter(notifications, function(x) {
return x.type != 'NewBlock' && x.type != 'BalanceUpdated' && x.type != 'NewOutgoingTxByThirdParty';
return !ignored[x.type];
});
var idToName = {};