mirror of https://github.com/BTCPrivate/copay.git
rollback
This commit is contained in:
parent
7340b4af29
commit
c15ec58643
|
@ -145,29 +145,26 @@ angular.module('copayApp.controllers').controller('SendController',
|
|||
}
|
||||
|
||||
$scope.loading = true;
|
||||
var comment = form.comment.$modelValue;
|
||||
var merchantData = $scope._merchantData;
|
||||
var address, amount;
|
||||
if (!merchantData) {
|
||||
address = form.address.$modelValue;
|
||||
amount = parseInt((form.amount.$modelValue * unitToSat).toFixed(0));
|
||||
}
|
||||
|
||||
$timeout(function() {
|
||||
var comment = form.comment.$modelValue;
|
||||
var merchantData = $scope._merchantData;
|
||||
var address, amount;
|
||||
if (!merchantData) {
|
||||
address = form.address.$modelValue;
|
||||
amount = parseInt((form.amount.$modelValue * unitToSat).toFixed(0));
|
||||
}
|
||||
|
||||
w.spend({
|
||||
merchantData: merchantData,
|
||||
toAddress: address,
|
||||
amountSat: amount,
|
||||
comment: comment,
|
||||
}, function(err, txid, status) {
|
||||
$scope.loading = false;
|
||||
if (err)
|
||||
w.spend({
|
||||
merchantData: merchantData,
|
||||
toAddress: address,
|
||||
amountSat: amount,
|
||||
comment: comment,
|
||||
}, function(err, txid, status) {
|
||||
$scope.loading = false;
|
||||
if (err)
|
||||
return $scope.setError(err);
|
||||
txStatus.notify(status);
|
||||
$scope.resetForm();
|
||||
});
|
||||
}, 100);
|
||||
});
|
||||
};
|
||||
|
||||
// QR code Scanner
|
||||
|
|
Loading…
Reference in New Issue