Skip to content

Commit

Permalink
Fix get items cache (#51)
Browse files Browse the repository at this point in the history
* fix getItems type

* changeset
  • Loading branch information
Zn4rK authored Apr 14, 2024
1 parent db1c8d9 commit 8e3a53a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/mean-clocks-leave.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@navita/engine": patch
---

fix getItems type
4 changes: 3 additions & 1 deletion packages/engine/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,9 @@ export class Engine {
return Object.keys(caches).reduce((acc, key) => ({
...acc,
[key]: this.caches[key as CacheKeys].items(caches[key as CacheKeys]),
}), {});
}), {} as {
[K in CacheKeys]?: ReturnType<Engine['caches'][K]['items']>;
});
}

clearUsedIds(filePath: string) {
Expand Down

0 comments on commit 8e3a53a

Please sign in to comment.