backend-manager 2.5.80 → 2.5.82
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "backend-manager",
|
|
3
|
-
"version": "2.5.
|
|
3
|
+
"version": "2.5.82",
|
|
4
4
|
"description": "Quick tools for developing Firebase functions",
|
|
5
5
|
"main": "src/manager/index.js",
|
|
6
6
|
"bin": {
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
"node-fetch": "^2.6.9",
|
|
52
52
|
"node-powertools": "^0.0.23",
|
|
53
53
|
"npm-api": "^1.0.1",
|
|
54
|
-
"paypal-server-api": "^1.0.
|
|
54
|
+
"paypal-server-api": "^1.0.2",
|
|
55
55
|
"pushid": "^1.0.0",
|
|
56
56
|
"semver": "^7.3.8",
|
|
57
57
|
"shortid": "^2.2.16",
|
|
@@ -57,13 +57,22 @@ SubscriptionResolver.prototype.resolve = function (options) {
|
|
|
57
57
|
|
|
58
58
|
// Set provider if not set
|
|
59
59
|
if (!profile.processor) {
|
|
60
|
-
if (
|
|
60
|
+
if (
|
|
61
|
+
// resource.billing_info
|
|
62
|
+
resource.create_time
|
|
63
|
+
) {
|
|
61
64
|
profile.processor = 'paypal';
|
|
62
|
-
} else if (
|
|
65
|
+
} else if (
|
|
66
|
+
resource.billing_period_unit
|
|
67
|
+
) {
|
|
63
68
|
profile.processor = 'chargebee';
|
|
64
|
-
} else if (
|
|
69
|
+
} else if (
|
|
70
|
+
resource.customer
|
|
71
|
+
) {
|
|
65
72
|
profile.processor = 'stripe';
|
|
66
|
-
} else if (
|
|
73
|
+
} else if (
|
|
74
|
+
resource.addresses
|
|
75
|
+
) {
|
|
67
76
|
profile.processor = 'coinbase';
|
|
68
77
|
} else {
|
|
69
78
|
throw new Error('Unable to determine subscription provider');
|