@ethersphere/bee-js 10.4.0 → 11.0.0
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/bee.js +17 -10
- package/dist/cjs/chunk/bmt.js +1 -2
- package/dist/cjs/chunk/cac.js +3 -3
- package/dist/cjs/chunk/soc.js +24 -15
- package/dist/cjs/feed/identifier.js +1 -2
- package/dist/cjs/feed/index.js +25 -16
- package/dist/cjs/feed/retrievable.js +1 -2
- package/dist/cjs/index.js +17 -7
- package/dist/cjs/modules/bytes.js +4 -5
- package/dist/cjs/modules/bzz.js +4 -5
- package/dist/cjs/modules/chunk.js +2 -3
- package/dist/cjs/modules/debug/balance.js +4 -5
- package/dist/cjs/modules/debug/chequebook.js +8 -9
- package/dist/cjs/modules/debug/connectivity.js +7 -8
- package/dist/cjs/modules/debug/settlements.js +2 -3
- package/dist/cjs/modules/debug/stake.js +6 -7
- package/dist/cjs/modules/debug/stamps.js +7 -8
- package/dist/cjs/modules/debug/states.js +6 -6
- package/dist/cjs/modules/debug/status.js +9 -9
- package/dist/cjs/modules/debug/transactions.js +4 -5
- package/dist/cjs/modules/envelope.js +1 -2
- package/dist/cjs/modules/feed.js +3 -4
- package/dist/cjs/modules/grantee.js +3 -4
- package/dist/cjs/modules/gsoc.js +2 -3
- package/dist/cjs/modules/pinning.js +4 -5
- package/dist/cjs/modules/pss.js +2 -3
- package/dist/cjs/modules/rchash.js +1 -2
- package/dist/cjs/modules/soc.js +1 -2
- package/dist/cjs/modules/status.js +2 -3
- package/dist/cjs/modules/stewardship.js +2 -3
- package/dist/cjs/modules/tag.js +5 -6
- package/dist/cjs/types/debug.js +3 -3
- package/dist/cjs/types/index.js +2 -2
- package/dist/cjs/utils/bytes.js +2 -2
- package/dist/cjs/utils/chunk-size.js +1 -2
- package/dist/cjs/utils/chunk-stream.browser.js +3 -4
- package/dist/cjs/utils/chunk-stream.js +3 -4
- package/dist/cjs/utils/cid.js +3 -3
- package/dist/cjs/utils/collection.browser.js +2 -3
- package/dist/cjs/utils/collection.js +5 -6
- package/dist/cjs/utils/collection.node.js +2 -3
- package/dist/cjs/utils/data.browser.js +1 -2
- package/dist/cjs/utils/data.js +1 -2
- package/dist/cjs/utils/expose.js +2 -1
- package/dist/cjs/utils/file.js +2 -3
- package/dist/cjs/utils/headers.js +2 -3
- package/dist/cjs/utils/http.js +2 -2
- package/dist/cjs/utils/pss.js +1 -2
- package/dist/cjs/utils/redundancy.js +3 -4
- package/dist/cjs/utils/stamps.js +12 -13
- package/dist/cjs/utils/tar-uploader.browser.js +1 -2
- package/dist/cjs/utils/tar-uploader.js +1 -2
- package/dist/cjs/utils/tar-writer.browser.js +1 -2
- package/dist/cjs/utils/tar-writer.js +1 -2
- package/dist/cjs/utils/type.js +34 -25
- package/dist/cjs/utils/url.js +3 -4
- package/dist/cjs/utils/workaround.js +2 -3
- package/dist/index.browser.min.js +1 -1
- package/dist/index.browser.min.js.map +1 -1
- package/dist/mjs/bee.js +0 -3
- package/dist/mjs/modules/debug/states.js +3 -0
- package/dist/mjs/modules/debug/status.js +1 -1
- package/dist/mjs/utils/expose.js +1 -1
- package/dist/types/bee.d.ts +0 -4
- package/dist/types/index.d.ts +1 -0
- package/dist/types/modules/bzz.d.ts +0 -1
- package/dist/types/modules/debug/status.d.ts +1 -1
- package/dist/types/modules/gsoc.d.ts +0 -1
- package/dist/types/modules/pss.d.ts +0 -1
- package/dist/types/types/debug.d.ts +1 -0
- package/dist/types/utils/constants.d.ts +3 -3
- package/dist/types/utils/error.d.ts +2 -2
- package/dist/types/utils/expose.d.ts +1 -1
- package/dist/types/utils/tar.browser.d.ts +1 -1
- package/dist/types/utils/tar.d.ts +0 -1
- package/dist/types/utils/type.d.ts +0 -1
- package/package.json +9 -12
package/dist/cjs/utils/url.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.isValidBeeUrl = isValidBeeUrl;
|
|
4
|
+
exports.assertBeeUrl = assertBeeUrl;
|
|
5
|
+
exports.stripLastSlash = stripLastSlash;
|
|
4
6
|
const error_1 = require("./error");
|
|
5
7
|
/**
|
|
6
8
|
* Validates that passed string is valid URL of Bee.
|
|
@@ -21,7 +23,6 @@ function isValidBeeUrl(url) {
|
|
|
21
23
|
return false;
|
|
22
24
|
}
|
|
23
25
|
}
|
|
24
|
-
exports.isValidBeeUrl = isValidBeeUrl;
|
|
25
26
|
/**
|
|
26
27
|
* Validates that passed string is valid URL of Bee, if not it throws BeeArgumentError.
|
|
27
28
|
* We support only HTTP and HTTPS protocols.
|
|
@@ -33,7 +34,6 @@ function assertBeeUrl(url) {
|
|
|
33
34
|
throw new error_1.BeeArgumentError('URL is not valid!', url);
|
|
34
35
|
}
|
|
35
36
|
}
|
|
36
|
-
exports.assertBeeUrl = assertBeeUrl;
|
|
37
37
|
/**
|
|
38
38
|
* Removes trailing slash out of the given string.
|
|
39
39
|
* @param url
|
|
@@ -44,4 +44,3 @@ function stripLastSlash(url) {
|
|
|
44
44
|
}
|
|
45
45
|
return url;
|
|
46
46
|
}
|
|
47
|
-
exports.stripLastSlash = stripLastSlash;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
// TODO: Remove this file after the issue is fixed
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.
|
|
4
|
+
exports.normalizeBatchTTL = normalizeBatchTTL;
|
|
5
|
+
exports.normalizeCurrentPrice = normalizeCurrentPrice;
|
|
5
6
|
function normalizeBatchTTL(batchTTL) {
|
|
6
7
|
if (!Number.isInteger(batchTTL)) {
|
|
7
8
|
return 1;
|
|
@@ -17,7 +18,6 @@ function normalizeBatchTTL(batchTTL) {
|
|
|
17
18
|
}
|
|
18
19
|
return batchTTL;
|
|
19
20
|
}
|
|
20
|
-
exports.normalizeBatchTTL = normalizeBatchTTL;
|
|
21
21
|
function normalizeCurrentPrice(currentPrice) {
|
|
22
22
|
if (!Number.isInteger(currentPrice)) {
|
|
23
23
|
return 24000;
|
|
@@ -27,4 +27,3 @@ function normalizeCurrentPrice(currentPrice) {
|
|
|
27
27
|
}
|
|
28
28
|
return currentPrice;
|
|
29
29
|
}
|
|
30
|
-
exports.normalizeCurrentPrice = normalizeCurrentPrice;
|