@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 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 | null>;
7
- get(objectId: string): Promise<ObjectReference | null>;
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 | null>;
10
- download(objectId: string): Promise<Buffer | null>;
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,IAAI,CAAC;IAa3F,GAAG,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,GAAG,IAAI,CAAC;IAUtD,MAAM,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAQvC,YAAY,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,YAAY,GAAG,IAAI,CAAC;IAU5D,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC;CAehE;AAED,eAAO,MAAM,EAAE,mBAA0B,CAAC"}
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 null;
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 null;
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 null;
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));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forge/os",
3
- "version": "1.1.2",
3
+ "version": "1.1.3-next.0",
4
4
  "description": "Forge Object Store SDK",
5
5
  "author": "Atlassian",
6
6
  "license": "UNLICENSED",