@binance/margin-trading 5.0.0 → 5.0.1
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/dist/index.js +6 -4
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +11 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -37,12 +37,11 @@ __export(index_exports, {
|
|
|
37
37
|
module.exports = __toCommonJS(index_exports);
|
|
38
38
|
|
|
39
39
|
// src/margin-trading.ts
|
|
40
|
-
var import_os = require("os");
|
|
41
40
|
var import_common9 = require("@binance/common");
|
|
42
41
|
|
|
43
42
|
// package.json
|
|
44
43
|
var name = "@binance/margin-trading";
|
|
45
|
-
var version = "5.0.
|
|
44
|
+
var version = "5.0.1";
|
|
46
45
|
|
|
47
46
|
// src/rest-api/index.ts
|
|
48
47
|
var rest_api_exports = {};
|
|
@@ -5574,13 +5573,16 @@ var RestAPI = class {
|
|
|
5574
5573
|
// src/margin-trading.ts
|
|
5575
5574
|
var MarginTrading = class {
|
|
5576
5575
|
constructor(config) {
|
|
5576
|
+
const userAgent = (0, import_common9.buildUserAgent)(name, version);
|
|
5577
5577
|
if (config?.configurationRestAPI) {
|
|
5578
|
-
const configRestAPI = new import_common9.ConfigurationRestAPI(
|
|
5578
|
+
const configRestAPI = new import_common9.ConfigurationRestAPI(
|
|
5579
|
+
config.configurationRestAPI
|
|
5580
|
+
);
|
|
5579
5581
|
configRestAPI.basePath = configRestAPI.basePath || import_common9.MARGIN_TRADING_REST_API_PROD_URL;
|
|
5580
5582
|
configRestAPI.baseOptions = configRestAPI.baseOptions || {};
|
|
5581
5583
|
configRestAPI.baseOptions.headers = {
|
|
5582
5584
|
...configRestAPI.baseOptions.headers || {},
|
|
5583
|
-
"User-Agent":
|
|
5585
|
+
"User-Agent": userAgent
|
|
5584
5586
|
};
|
|
5585
5587
|
this.restAPI = new RestAPI(configRestAPI);
|
|
5586
5588
|
}
|