(
expr: LoadSubsetOptions[`where`],
)
| 2708 | // Find the inArray expression in loadSubset calls |
| 2709 | // It may be wrapped in `and` since requestSnapshot combines expressions |
| 2710 | const findInArrayExpr = ( |
| 2711 | expr: LoadSubsetOptions[`where`], |
| 2712 | ): Func | undefined => { |
| 2713 | if (!(expr instanceof Func)) return undefined |
| 2714 | if (expr.name === `in`) return expr |
| 2715 | if (expr.name === `and` || expr.name === `or`) { |
| 2716 | for (const arg of expr.args) { |
| 2717 | const found = findInArrayExpr(arg) |
| 2718 | if (found) return found |
| 2719 | } |
| 2720 | } |
| 2721 | return undefined |
| 2722 | } |
| 2723 | |
| 2724 | const inExpr = capturedOptions |
| 2725 | .map((opt) => findInArrayExpr(opt.where)) |
no outgoing calls
no test coverage detected