@fireproof/core 0.14.1 → 0.14.2
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/browser/fireproof.cjs +7 -11
- package/dist/browser/fireproof.cjs.map +3 -3
- package/dist/browser/fireproof.esm.js +7 -11
- package/dist/browser/fireproof.esm.js.map +3 -3
- package/dist/browser/fireproof.iife.js +7 -11
- package/dist/browser/fireproof.iife.js.map +3 -3
- package/dist/node/fireproof.cjs +7 -11
- package/dist/node/fireproof.cjs.map +3 -3
- package/dist/node/fireproof.esm.js +7 -11
- package/dist/node/fireproof.esm.js.map +3 -3
- package/dist/types/version.d.ts +1 -1
- package/package.json +2 -2
@@ -20977,7 +20977,7 @@ import { homedir } from "os";
|
|
20977
20977
|
import { mkdir, readFile, writeFile, unlink } from "fs/promises";
|
20978
20978
|
|
20979
20979
|
// src/version.ts
|
20980
|
-
var PACKAGE_VERSION = "0.14.
|
20980
|
+
var PACKAGE_VERSION = "0.14.2";
|
20981
20981
|
|
20982
20982
|
// src/store.ts
|
20983
20983
|
var match = PACKAGE_VERSION.match(/^([^.]*\.[^.]*)/);
|
@@ -27413,7 +27413,7 @@ var import_err_code7 = __toESM(require_err_code(), 1);
|
|
27413
27413
|
// ../../node_modules/.pnpm/ipfs-unixfs@11.0.2/node_modules/ipfs-unixfs/dist/src/index.js
|
27414
27414
|
var import_err_code5 = __toESM(require_err_code(), 1);
|
27415
27415
|
|
27416
|
-
// ../../node_modules/.pnpm/protons-runtime@5.0.2/node_modules/protons-runtime/dist/src/utils.js
|
27416
|
+
// ../../node_modules/.pnpm/protons-runtime@5.0.2_uint8arraylist@2.4.3/node_modules/protons-runtime/dist/src/utils.js
|
27417
27417
|
var import_reader3 = __toESM(require_reader(), 1);
|
27418
27418
|
var import_reader_buffer = __toESM(require_reader_buffer(), 1);
|
27419
27419
|
var import_minimal2 = __toESM(require_minimal(), 1);
|
@@ -27463,13 +27463,13 @@ function writer() {
|
|
27463
27463
|
return patchWriter(import_writer2.default.create());
|
27464
27464
|
}
|
27465
27465
|
|
27466
|
-
// ../../node_modules/.pnpm/protons-runtime@5.0.2/node_modules/protons-runtime/dist/src/decode.js
|
27466
|
+
// ../../node_modules/.pnpm/protons-runtime@5.0.2_uint8arraylist@2.4.3/node_modules/protons-runtime/dist/src/decode.js
|
27467
27467
|
function decodeMessage(buf3, codec) {
|
27468
27468
|
const r = reader(buf3 instanceof Uint8Array ? buf3 : buf3.subarray());
|
27469
27469
|
return codec.decode(r);
|
27470
27470
|
}
|
27471
27471
|
|
27472
|
-
// ../../node_modules/.pnpm/protons-runtime@5.0.2/node_modules/protons-runtime/dist/src/encode.js
|
27472
|
+
// ../../node_modules/.pnpm/protons-runtime@5.0.2_uint8arraylist@2.4.3/node_modules/protons-runtime/dist/src/encode.js
|
27473
27473
|
function encodeMessage(message2, codec) {
|
27474
27474
|
const w = writer();
|
27475
27475
|
codec.encode(message2, w, {
|
@@ -27478,7 +27478,7 @@ function encodeMessage(message2, codec) {
|
|
27478
27478
|
return w.finish();
|
27479
27479
|
}
|
27480
27480
|
|
27481
|
-
// ../../node_modules/.pnpm/protons-runtime@5.0.2/node_modules/protons-runtime/dist/src/codec.js
|
27481
|
+
// ../../node_modules/.pnpm/protons-runtime@5.0.2_uint8arraylist@2.4.3/node_modules/protons-runtime/dist/src/codec.js
|
27482
27482
|
var CODEC_TYPES;
|
27483
27483
|
(function(CODEC_TYPES2) {
|
27484
27484
|
CODEC_TYPES2[CODEC_TYPES2["VARINT"] = 0] = "VARINT";
|
@@ -27497,7 +27497,7 @@ function createCodec(name8, type2, encode19, decode21) {
|
|
27497
27497
|
};
|
27498
27498
|
}
|
27499
27499
|
|
27500
|
-
// ../../node_modules/.pnpm/protons-runtime@5.0.2/node_modules/protons-runtime/dist/src/codecs/enum.js
|
27500
|
+
// ../../node_modules/.pnpm/protons-runtime@5.0.2_uint8arraylist@2.4.3/node_modules/protons-runtime/dist/src/codecs/enum.js
|
27501
27501
|
function enumeration(v) {
|
27502
27502
|
function findValue(val) {
|
27503
27503
|
if (v[val.toString()] == null) {
|
@@ -27516,7 +27516,7 @@ function enumeration(v) {
|
|
27516
27516
|
return createCodec("enum", CODEC_TYPES.VARINT, encode19, decode21);
|
27517
27517
|
}
|
27518
27518
|
|
27519
|
-
// ../../node_modules/.pnpm/protons-runtime@5.0.2/node_modules/protons-runtime/dist/src/codecs/message.js
|
27519
|
+
// ../../node_modules/.pnpm/protons-runtime@5.0.2_uint8arraylist@2.4.3/node_modules/protons-runtime/dist/src/codecs/message.js
|
27520
27520
|
function message(encode19, decode21) {
|
27521
27521
|
return createCodec("message", CODEC_TYPES.LENGTH_DELIMITED, encode19, decode21);
|
27522
27522
|
}
|
@@ -30132,11 +30132,9 @@ async function processFileset(blocks, files, publicFiles = false) {
|
|
30132
30132
|
const dbBlockstore = blocks.parent;
|
30133
30133
|
const t = new Transaction(dbBlockstore);
|
30134
30134
|
const didPut = [];
|
30135
|
-
let totalSize = 0;
|
30136
30135
|
for (const filename in files) {
|
30137
30136
|
if (File === files[filename].constructor) {
|
30138
30137
|
const file = files[filename];
|
30139
|
-
totalSize += file.size;
|
30140
30138
|
const { cid, blocks: fileBlocks } = await encodeFile2(file);
|
30141
30139
|
didPut.push(filename);
|
30142
30140
|
for (const block of fileBlocks) {
|
@@ -30145,8 +30143,6 @@ async function processFileset(blocks, files, publicFiles = false) {
|
|
30145
30143
|
files[filename] = { cid, type: file.type, size: file.size };
|
30146
30144
|
}
|
30147
30145
|
}
|
30148
|
-
if (totalSize > 1024 * 1024 * 1)
|
30149
|
-
throw new Error("Sync limit for files in a single update is 1MB");
|
30150
30146
|
if (didPut.length) {
|
30151
30147
|
const car = await dbBlockstore.loader?.commit(t, { files }, { public: publicFiles });
|
30152
30148
|
if (car) {
|