Disables BitPay Card from appConfig
This commit is contained in:
parent
02f84b8a60
commit
f13d9ca6a4
2 changed files with 7 additions and 1 deletions
|
|
@ -1,6 +1,6 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
angular.module('copayApp.services').factory('bitpayCardService', function($log, $rootScope, $filter, lodash, storageService, bitauthService, platformInfo, moment, appIdentityService, bitpayService, nextStepsService, configService, txFormatService) {
|
angular.module('copayApp.services').factory('bitpayCardService', function($log, $rootScope, $filter, lodash, storageService, bitauthService, platformInfo, moment, appIdentityService, bitpayService, nextStepsService, configService, txFormatService, appConfigService) {
|
||||||
var root = {};
|
var root = {};
|
||||||
|
|
||||||
var _setError = function(msg, e) {
|
var _setError = function(msg, e) {
|
||||||
|
|
@ -1323,6 +1323,8 @@ angular.module('copayApp.services').factory('bitpayCardService', function($log,
|
||||||
|
|
||||||
|
|
||||||
root.registerNextStep = function() {
|
root.registerNextStep = function() {
|
||||||
|
// Disable BitPay Card
|
||||||
|
if (!appConfigService._enabledExtensions.debitcard) return;
|
||||||
root.getCards(function(err, cards) {
|
root.getCards(function(err, cards) {
|
||||||
if (lodash.isEmpty(cards)) {
|
if (lodash.isEmpty(cards)) {
|
||||||
nextStepsService.register(nextStepItem);
|
nextStepsService.register(nextStepItem);
|
||||||
|
|
|
||||||
|
|
@ -165,6 +165,10 @@ angular.module('copayApp.services').factory('incomingData', function($log, $stat
|
||||||
|
|
||||||
// BitPayCard Authentication
|
// BitPayCard Authentication
|
||||||
} else if (data && data.indexOf(appConfigService.name + '://') === 0) {
|
} else if (data && data.indexOf(appConfigService.name + '://') === 0) {
|
||||||
|
|
||||||
|
// Disable BitPay Card
|
||||||
|
if (!appConfigService._enabledExtensions.debitcard) return false;
|
||||||
|
|
||||||
var secret = getParameterByName('secret', data);
|
var secret = getParameterByName('secret', data);
|
||||||
var email = getParameterByName('email', data);
|
var email = getParameterByName('email', data);
|
||||||
var otp = getParameterByName('otp', data);
|
var otp = getParameterByName('otp', data);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue