Skip to content

Commit

Permalink
fix: storing empty representations
Browse files Browse the repository at this point in the history
  • Loading branch information
tpluscode committed Dec 23, 2020
1 parent 52c94cc commit 48362a0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/afraid-seals-boil.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"alcaeus": patch
---

Empty representation cannot be retrieved back from ResourceStore
2 changes: 1 addition & 1 deletion src/ResourceStore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export default class ResourceStoreImpl<D extends DatasetIndexed> implements Reso
const node = cf({ dataset: this.dataset, graph })
const response = this.responses.get(graph)

if (!node.out().values.length || !response) {
if (!response) {
return undefined
}

Expand Down

0 comments on commit 48362a0

Please sign in to comment.