(state: readonly FilterResult[], relationPath: string)
| 23 | export { get } from "./utils.ts" |
| 24 | |
| 25 | const stripRelationFilterPaths = (state: readonly FilterResult[], relationPath: string): readonly FilterResult[] => { |
| 26 | const prefix = `${relationPath}.-1.` |
| 27 | return state.map((entry) => |
| 28 | "path" in entry |
| 29 | ? { |
| 30 | ...entry, |
| 31 | path: entry.path.startsWith(prefix) ? entry.path.slice(prefix.length) : entry.path |
| 32 | } |
| 33 | : { |
| 34 | ...entry, |
| 35 | result: stripRelationFilterPaths(entry.result, relationPath) |
| 36 | } |
| 37 | ) |
| 38 | } |
| 39 | |
| 40 | const emptyValueFor = (tag: ComputedProjectionIrExpression["_tag"]) => { |
| 41 | switch (tag) { |
no test coverage detected
searching dependent graphs…