@blocklet/sdk 1.16.14-beta-9743e8e2 → 1.16.14-beta-c81e5ca0
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/lib/config.js +1 -1
- package/package.json +7 -7
- package/lib/util/axios.d.ts +0 -2
- package/lib/util/axios.js +0 -26
package/lib/config.js
CHANGED
|
@@ -12,7 +12,7 @@ const env_1 = __importDefault(require("@blocklet/env"));
|
|
|
12
12
|
const constant_1 = require("@blocklet/constant");
|
|
13
13
|
const util_1 = require("@blocklet/env/lib/util");
|
|
14
14
|
const util_2 = require("@blocklet/meta/lib/util");
|
|
15
|
-
const axios_1 = __importDefault(require("
|
|
15
|
+
const axios_1 = __importDefault(require("axios"));
|
|
16
16
|
const version_1 = require("./version");
|
|
17
17
|
const notification_1 = __importDefault(require("./service/notification"));
|
|
18
18
|
const events = new events_1.default();
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "1.16.14-beta-
|
|
6
|
+
"version": "1.16.14-beta-c81e5ca0",
|
|
7
7
|
"description": "graphql client to read/write data on abt node",
|
|
8
8
|
"main": "lib/index.js",
|
|
9
9
|
"typings": "lib/index.d.ts",
|
|
@@ -26,15 +26,15 @@
|
|
|
26
26
|
"author": "linchen1987 <linchen.1987@foxmail.com> (http://github.com/linchen1987)",
|
|
27
27
|
"license": "Apache-2.0",
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@abtnode/client": "1.16.14-beta-
|
|
30
|
-
"@abtnode/constant": "1.16.14-beta-
|
|
29
|
+
"@abtnode/client": "1.16.14-beta-c81e5ca0",
|
|
30
|
+
"@abtnode/constant": "1.16.14-beta-c81e5ca0",
|
|
31
31
|
"@arcblock/did": "1.18.88",
|
|
32
32
|
"@arcblock/did-auth": "1.18.88",
|
|
33
33
|
"@arcblock/jwt": "1.18.88",
|
|
34
34
|
"@arcblock/ws": "1.18.88",
|
|
35
|
-
"@blocklet/constant": "1.16.14-beta-
|
|
36
|
-
"@blocklet/env": "1.16.14-beta-
|
|
37
|
-
"@blocklet/meta": "1.16.14-beta-
|
|
35
|
+
"@blocklet/constant": "1.16.14-beta-c81e5ca0",
|
|
36
|
+
"@blocklet/env": "1.16.14-beta-c81e5ca0",
|
|
37
|
+
"@blocklet/meta": "1.16.14-beta-c81e5ca0",
|
|
38
38
|
"@did-connect/authenticator": "^2.2.0",
|
|
39
39
|
"@did-connect/handler": "^2.2.0",
|
|
40
40
|
"@nedb/core": "^2.1.5",
|
|
@@ -73,5 +73,5 @@
|
|
|
73
73
|
"ts-node": "^10.9.1",
|
|
74
74
|
"typescript": "^5.0.4"
|
|
75
75
|
},
|
|
76
|
-
"gitHead": "
|
|
76
|
+
"gitHead": "7b7029946719716f857b646f1c963702a3bf5e88"
|
|
77
77
|
}
|
package/lib/util/axios.d.ts
DELETED
package/lib/util/axios.js
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
const Axios = require('axios');
|
|
3
|
-
const http = require('http');
|
|
4
|
-
const https = require('https');
|
|
5
|
-
// Force all requests routed to local host
|
|
6
|
-
const getAgent = (type) => {
|
|
7
|
-
const agent = { http, https }[type].Agent();
|
|
8
|
-
agent.originCreateConnection = agent.createConnection;
|
|
9
|
-
agent.createConnection = (options, callback) => {
|
|
10
|
-
options.lookup = (hostname, opts, cb) => {
|
|
11
|
-
const host = {
|
|
12
|
-
address: '127.0.0.1',
|
|
13
|
-
family: 4,
|
|
14
|
-
};
|
|
15
|
-
return cb(null, host.address, host.family);
|
|
16
|
-
};
|
|
17
|
-
return agent.originCreateConnection(options, callback);
|
|
18
|
-
};
|
|
19
|
-
return agent;
|
|
20
|
-
};
|
|
21
|
-
const axios = Axios.create({
|
|
22
|
-
proxy: false,
|
|
23
|
-
httpAgent: getAgent('http'),
|
|
24
|
-
httpsAgent: getAgent('https'),
|
|
25
|
-
});
|
|
26
|
-
module.exports = axios;
|