diff --git a/js/controllers/send.js b/js/controllers/send.js index 84c6d7efcc6..4a5f35bc39c 100644 --- a/js/controllers/send.js +++ b/js/controllers/send.js @@ -142,7 +142,7 @@ angular.module('copayApp.controllers').controller('SendController', }); } - if (w.isShared()) { + if (w.requiresMultipleSignatures()) { $scope.loading = false; var message = 'The transaction proposal has been created'; if (merchantData) { diff --git a/js/models/Wallet.js b/js/models/Wallet.js index a40d7cd619a..ef03b775ad8 100644 --- a/js/models/Wallet.js +++ b/js/models/Wallet.js @@ -2472,6 +2472,14 @@ Wallet.prototype.isShared = function() { return this.totalCopayers > 1; }; +/** + * @desc Returns true if more than one signature is required + * @return {boolean} + */ +Wallet.prototype.requiresMultipleSignatures = function() { + return this.requiredCopayers > 1; +}; + /** * @desc Returns true if the keyring is complete and all users have backed up the wallet * @return {boolean} diff --git a/test/mocks/FakeWallet.js b/test/mocks/FakeWallet.js index bec56a931a3..0010d5fe64d 100644 --- a/test/mocks/FakeWallet.js +++ b/test/mocks/FakeWallet.js @@ -95,6 +95,10 @@ FakeWallet.prototype.isShared = function() { return this.totalCopayers > 1; } +FakeWallet.prototype.requiresMultipleSignatures = function() { + return this.requiredCopayers > 1; +}; + FakeWallet.prototype.isReady = function() { return true; };