@ethersphere/bee-js 6.7.4 → 6.8.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/cjs/modules/debug/status.js +1 -1
- package/dist/cjs/utils/http.js +1 -0
- package/dist/cjs/utils/stream.js +1 -1
- package/dist/cjs/utils/type.js +1 -17
- package/dist/index.browser.min.js +1 -1
- package/dist/index.browser.min.js.map +1 -1
- package/dist/mjs/modules/debug/status.js +1 -1
- package/dist/mjs/utils/http.js +1 -0
- package/dist/mjs/utils/stream.js +1 -1
- package/dist/mjs/utils/type.js +1 -17
- package/dist/types/modules/debug/status.d.ts +1 -1
- package/dist/types/utils/error.d.ts +2 -2
- package/dist/types/utils/type.d.ts +1 -10
- package/package.json +6 -5
|
@@ -8,7 +8,7 @@ const major_js_1 = __importDefault(require("semver/functions/major.js"));
|
|
|
8
8
|
const http_1 = require("../../utils/http");
|
|
9
9
|
// Following lines bellow are automatically updated with GitHub Action when Bee version is updated
|
|
10
10
|
// so if you are changing anything about them change the `update_bee` action accordingly!
|
|
11
|
-
exports.SUPPORTED_BEE_VERSION_EXACT = '1.
|
|
11
|
+
exports.SUPPORTED_BEE_VERSION_EXACT = '1.18.2-759f56f';
|
|
12
12
|
exports.SUPPORTED_API_VERSION = '4.0.0';
|
|
13
13
|
exports.SUPPORTED_DEBUG_API_VERSION = '4.0.0';
|
|
14
14
|
exports.SUPPORTED_BEE_VERSION = exports.SUPPORTED_BEE_VERSION_EXACT.substring(0, exports.SUPPORTED_BEE_VERSION_EXACT.indexOf('-'));
|
package/dist/cjs/utils/http.js
CHANGED
|
@@ -44,6 +44,7 @@ async function http(options, config) {
|
|
|
44
44
|
const requestConfig = cafe_utility_1.Objects.deepMerge3(exports.DEFAULT_HTTP_CONFIG, config, options);
|
|
45
45
|
maybeRunOnRequestHook(options, requestConfig);
|
|
46
46
|
const response = await (0, axios_1.default)(requestConfig);
|
|
47
|
+
// TODO: https://github.com/axios/axios/pull/6253
|
|
47
48
|
return response;
|
|
48
49
|
}
|
|
49
50
|
catch (e) {
|
package/dist/cjs/utils/stream.js
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.normalizeToReadableStream = exports.readableWebToNode = exports.readableNodeToWeb = exports.isNodeReadable = exports.isReadableStream = exports.isReadable = void 0;
|
|
4
4
|
const stream_1 = require("stream");
|
|
5
|
-
const type_1 = require("./type");
|
|
6
5
|
const web_streams_polyfill_1 = require("web-streams-polyfill");
|
|
6
|
+
const type_1 = require("./type");
|
|
7
7
|
const NodeReadable = stream_1.Readable || class {
|
|
8
8
|
};
|
|
9
9
|
/**
|
package/dist/cjs/utils/type.js
CHANGED
|
@@ -23,16 +23,6 @@ function isObject(value) {
|
|
|
23
23
|
return value !== null && typeof value === 'object';
|
|
24
24
|
}
|
|
25
25
|
exports.isObject = isObject;
|
|
26
|
-
/**
|
|
27
|
-
* Generally it is discouraged to use `object` type, but in this case I think
|
|
28
|
-
* it is best to do so as it is possible to easily convert from `object`to other
|
|
29
|
-
* types, which will be usually the case after asserting that the object is
|
|
30
|
-
* strictly object. With for example Record<string, unknown> you have to first
|
|
31
|
-
* cast it to `unknown` which I think bit defeat the purpose.
|
|
32
|
-
*
|
|
33
|
-
* @param value
|
|
34
|
-
*/
|
|
35
|
-
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
36
26
|
function isStrictlyObject(value) {
|
|
37
27
|
return isObject(value) && !Array.isArray(value);
|
|
38
28
|
}
|
|
@@ -245,13 +235,7 @@ function isTag(value) {
|
|
|
245
235
|
if (!isStrictlyObject(value)) {
|
|
246
236
|
return false;
|
|
247
237
|
}
|
|
248
|
-
|
|
249
|
-
const numberProperties = ['total', 'processed', 'synced', 'uid'];
|
|
250
|
-
const correctNumberProperties = numberProperties.every(numberProperty => typeof tag[numberProperty] === 'number');
|
|
251
|
-
if (!correctNumberProperties || !tag.startedAt || typeof tag.startedAt !== 'string') {
|
|
252
|
-
return false;
|
|
253
|
-
}
|
|
254
|
-
return true;
|
|
238
|
+
return Boolean(value.uid);
|
|
255
239
|
}
|
|
256
240
|
exports.isTag = isTag;
|
|
257
241
|
function assertTag(value) {
|