Build successful for connected-solid

main
Jackson Morgan 6 months ago
parent a2d03e5431
commit eb7e36a22b
  1. 17
      packages/connected-solid/src/getStorageFromWebId.ts
  2. 4
      packages/connected-solid/src/resources/SolidLeaf.ts

@ -38,13 +38,18 @@ export async function getStorageFromWebId(
const webIdResource = dataset.getResource(webId) as SolidLeaf; const webIdResource = dataset.getResource(webId) as SolidLeaf;
const readResult = await webIdResource.readIfUnfetched(); const readResult = await webIdResource.readIfUnfetched();
if (readResult.isError) return readResult; if (readResult.isError) return readResult;
const profile = this.usingType(ProfileWithStorageShapeType).fromSubject( const profile = dataset
webId, .usingType(ProfileWithStorageShapeType)
); .fromSubject(webId);
if (profile.storage && profile.storage.size > 0) { if (profile.storage && profile.storage.size > 0) {
const containers = profile.storage.map((storageNode) => const containers = profile.storage
this.getResource(storageNode["@id"] as SolidContainerUri), .map((storageNode) =>
); dataset.getResource(storageNode["@id"] as SolidContainerUri),
)
.filter(
(container): container is SolidContainer =>
container.type === "SolidContainer",
);
return { return {
type: "getStorageContainerFromWebIdSuccess", type: "getStorageContainerFromWebIdSuccess",
isError: false, isError: false,

@ -61,11 +61,11 @@ export class SolidLeaf extends SolidResource {
* The status of the last request made for this leaf * The status of the last request made for this leaf
*/ */
status: status:
| SharedStatuses<this> | SharedStatuses<SolidLeaf>
| ReadLeafResult | ReadLeafResult
| LeafCreateAndOverwriteResult | LeafCreateAndOverwriteResult
| LeafCreateIfAbsentResult | LeafCreateIfAbsentResult
| UpdateResult<this>; | UpdateResult<SolidLeaf>;
/** /**
* @internal * @internal

Loading…
Cancel
Save