@riocrypto/common-server 1.0.710 → 1.0.712
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/build/helpers/get-platform-and-partner-fees.js +2 -2
- package/build/index.d.ts +1 -0
- package/build/index.js +1 -0
- package/package.json +2 -2
- /package/build/helpers/{calculateAggregateVolume.d.ts → calculate-aggregate-volume.d.ts} +0 -0
- /package/build/helpers/{calculateAggregateVolume.js → calculate-aggregate-volume.js} +0 -0
|
@@ -16,7 +16,7 @@ const kapstar_client_1 = require("../clients/kapstar-client");
|
|
|
16
16
|
const currency_api_client_1 = require("../clients/currency-api-client");
|
|
17
17
|
const partner_1 = require("../models/partner");
|
|
18
18
|
const user_1 = require("../models/user");
|
|
19
|
-
const
|
|
19
|
+
const calculate_aggregate_volume_1 = require("./calculate-aggregate-volume");
|
|
20
20
|
const getPlatformAndPartnerFees = (mongoose, amountFiat, fiat, processor, country, partnerId, brokerCustomerId, user) => __awaiter(void 0, void 0, void 0, function* () {
|
|
21
21
|
var _a;
|
|
22
22
|
let platformFeeFiat;
|
|
@@ -60,7 +60,7 @@ const getPlatformAndPartnerFees = (mongoose, amountFiat, fiat, processor, countr
|
|
|
60
60
|
else if (user === null || user === void 0 ? void 0 : user.platformFeeRanges) {
|
|
61
61
|
let volume;
|
|
62
62
|
if ((_a = user === null || user === void 0 ? void 0 : user.attributes) === null || _a === void 0 ? void 0 : _a.includes(common_1.UserAttribute.summedVolumeFees)) {
|
|
63
|
-
volume = yield (0,
|
|
63
|
+
volume = yield (0, calculate_aggregate_volume_1.calculateAggregateVolume)(user, 14);
|
|
64
64
|
}
|
|
65
65
|
else {
|
|
66
66
|
volume = Number(amountUSD);
|
package/build/index.d.ts
CHANGED
package/build/index.js
CHANGED
|
@@ -59,3 +59,4 @@ __exportStar(require("./clients/currency-api-client"), exports);
|
|
|
59
59
|
__exportStar(require("./helpers/get-user-helper"), exports);
|
|
60
60
|
__exportStar(require("./helpers/get-platform-and-partner-fees"), exports);
|
|
61
61
|
__exportStar(require("./helpers/get-network-fees"), exports);
|
|
62
|
+
__exportStar(require("./helpers/calculate-aggregate-volume"), exports);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@riocrypto/common-server",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.712",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./build/index.js",
|
|
6
6
|
"types": "./build/index.d.ts",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"@aws-sdk/client-s3": "^3.297.0",
|
|
25
25
|
"@everapi/currencyapi-js": "^1.0.6",
|
|
26
26
|
"@google-cloud/storage": "^6.9.5",
|
|
27
|
-
"@riocrypto/common": "^1.0.
|
|
27
|
+
"@riocrypto/common": "^1.0.635",
|
|
28
28
|
"@types/express": "^4.17.13",
|
|
29
29
|
"axios": "^0.27.2",
|
|
30
30
|
"ccxt": "^3.0.30",
|
|
File without changes
|
|
File without changes
|