@datapos/datapos-shared 0.3.534 → 0.3.536
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.
|
@@ -53,19 +53,17 @@ function y(r) {
|
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
function i(r) {
|
|
56
|
-
if (r
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
return new Error("Unknown error");
|
|
68
|
-
}
|
|
56
|
+
if (r instanceof Error) return r;
|
|
57
|
+
if (typeof r == "string") return new Error(r);
|
|
58
|
+
if (typeof r == "number" || typeof r == "boolean" || typeof r == "bigint") return new Error(String(r));
|
|
59
|
+
if (typeof r == "symbol") return new Error(r.description ?? "Unknown error");
|
|
60
|
+
if (typeof r == "object")
|
|
61
|
+
try {
|
|
62
|
+
return new Error(JSON.stringify(r));
|
|
63
|
+
} catch {
|
|
64
|
+
return new Error("Unknown error");
|
|
65
|
+
}
|
|
66
|
+
return new Error("Unknown error");
|
|
69
67
|
}
|
|
70
68
|
function R(r) {
|
|
71
69
|
const n = /* @__PURE__ */ new Set(), o = [];
|
|
@@ -193,8 +193,8 @@ interface ListNodesResult {
|
|
|
193
193
|
* Preview object options.
|
|
194
194
|
*/
|
|
195
195
|
interface PreviewObjectOptions extends EngineOperationOptions {
|
|
196
|
-
chunkSize
|
|
197
|
-
extension
|
|
196
|
+
chunkSize: number | undefined;
|
|
197
|
+
extension: string | undefined;
|
|
198
198
|
path: string;
|
|
199
199
|
}
|
|
200
200
|
/**
|
|
@@ -208,7 +208,7 @@ interface RemoveRecordsOptions extends EngineOperationOptions {
|
|
|
208
208
|
* Retrieve chunks options.
|
|
209
209
|
*/
|
|
210
210
|
interface RetrieveChunksOptions extends EngineOperationOptions {
|
|
211
|
-
chunkSize
|
|
211
|
+
chunkSize: number | undefined;
|
|
212
212
|
encodingId: string;
|
|
213
213
|
path: string;
|
|
214
214
|
valueDelimiterId: ValueDelimiterId;
|
|
@@ -217,7 +217,7 @@ interface RetrieveChunksOptions extends EngineOperationOptions {
|
|
|
217
217
|
* Retrieve records options and summary.
|
|
218
218
|
*/
|
|
219
219
|
interface RetrieveRecordsOptions extends EngineOperationOptions {
|
|
220
|
-
chunkSize
|
|
220
|
+
chunkSize: number | undefined;
|
|
221
221
|
encodingId: string;
|
|
222
222
|
path: string;
|
|
223
223
|
valueDelimiterId: ValueDelimiterId;
|
|
@@ -72,7 +72,7 @@ declare function ignoreErrors(action: () => void): void;
|
|
|
72
72
|
/** Normalizes an unknown thrown value into an {@link Error}.
|
|
73
73
|
* This function should be used at error boundaries to guarantee consistent error handling.
|
|
74
74
|
*/
|
|
75
|
-
declare function normalizeToError(value
|
|
75
|
+
declare function normalizeToError(value: unknown): Error;
|
|
76
76
|
/** Serializes an error and its cause chain into a flat structure.
|
|
77
77
|
* - Errors are ordered from outermost to root cause.
|
|
78
78
|
* - Cycles in the cause chain are safely ignored.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@datapos/datapos-shared",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.536",
|
|
4
4
|
"description": "A library containing common constants, types and utilities used across all Data Positioning projects.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Jonathan Terrell <terrell.jm@gmail.com>",
|