MCPcopy Create free account
hub / github.com/microsoft/SandDance / narrow

Function narrow

packages/search-expression/src/narrow.ts:6–14  ·  view source on GitHub ↗
(a: Search, b: Search)

Source from the content-addressed store, hash-verified

4import { Search } from './types';
5
6export function narrow(a: Search, b: Search) {
7 if (!a) {
8 return b;
9 }
10 const arrs = [a, b].map(ensureSearchExpressionGroupArray);
11 const [arrA, arrB] = arrs;
12 arrB[0].clause = '&&';
13 return arrA.concat(arrB);
14}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected