@forge/os 1.1.2 → 1.1.3-next.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/out/os.d.ts +4 -4
- package/out/os.d.ts.map +1 -1
- package/out/os.js +3 -3
- package/package.json +1 -1
package/out/os.d.ts
CHANGED
|
@@ -3,11 +3,11 @@ import { ObjectReference, VersionsList } from './types';
|
|
|
3
3
|
export declare class ObjectStoreClient {
|
|
4
4
|
private sendRequest;
|
|
5
5
|
private requestJson;
|
|
6
|
-
put(objectId: string, buffer: Buffer, ttlSeconds?: number): Promise<ObjectReference |
|
|
7
|
-
get(objectId: string): Promise<ObjectReference |
|
|
6
|
+
put(objectId: string, buffer: Buffer, ttlSeconds?: number): Promise<ObjectReference | undefined>;
|
|
7
|
+
get(objectId: string): Promise<ObjectReference | undefined>;
|
|
8
8
|
delete(objectId: string): Promise<void>;
|
|
9
|
-
listVersions(objectId: string): Promise<VersionsList |
|
|
10
|
-
download(objectId: string): Promise<Buffer |
|
|
9
|
+
listVersions(objectId: string): Promise<VersionsList | undefined>;
|
|
10
|
+
download(objectId: string): Promise<Buffer | undefined>;
|
|
11
11
|
}
|
|
12
12
|
export declare const os: ObjectStoreClient;
|
|
13
13
|
//# sourceMappingURL=os.d.ts.map
|
package/out/os.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"os.d.ts","sourceRoot":"","sources":["../src/os.ts"],"names":[],"mappings":";AAIA,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAQxD,qBAAa,iBAAiB;YAEd,WAAW;YASX,WAAW;IAqCZ,GAAG,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,GAAG,
|
|
1
|
+
{"version":3,"file":"os.d.ts","sourceRoot":"","sources":["../src/os.ts"],"names":[],"mappings":";AAIA,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAQxD,qBAAa,iBAAiB;YAEd,WAAW;YASX,WAAW;IAqCZ,GAAG,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,GAAG,SAAS,CAAC;IAahG,GAAG,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,GAAG,SAAS,CAAC;IAU3D,MAAM,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAQvC,YAAY,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,GAAG,SAAS,CAAC;IAUjE,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC;CAerE;AAED,eAAO,MAAM,EAAE,mBAA0B,CAAC"}
|
package/out/os.js
CHANGED
|
@@ -25,12 +25,12 @@ class ObjectStoreClient {
|
|
|
25
25
|
body
|
|
26
26
|
});
|
|
27
27
|
if (response.status === 404) {
|
|
28
|
-
return
|
|
28
|
+
return undefined;
|
|
29
29
|
}
|
|
30
30
|
await (0, error_handling_1.checkResponseError)(response);
|
|
31
31
|
const responseText = await response.text();
|
|
32
32
|
if (!responseText || responseText.trim().length === 0) {
|
|
33
|
-
return
|
|
33
|
+
return undefined;
|
|
34
34
|
}
|
|
35
35
|
try {
|
|
36
36
|
return JSON.parse(responseText);
|
|
@@ -68,7 +68,7 @@ class ObjectStoreClient {
|
|
|
68
68
|
}
|
|
69
69
|
});
|
|
70
70
|
if (response.status === 404) {
|
|
71
|
-
return
|
|
71
|
+
return undefined;
|
|
72
72
|
}
|
|
73
73
|
await (0, error_handling_1.checkResponseError)(response);
|
|
74
74
|
return await response.arrayBuffer().then((buffer) => Buffer.from(buffer));
|