import sift from 'sift' ; import { FilterQuery } from '@deepkit/rpc' ; export function findQuerySatisfied < T extends { [ index ] : any ; } > ( target , query ) { return ( sift as any ) ( query as any , [ target ] as any [ ] ) . length > 0 ; } export function normalizeDirectory ( path ) { if ( path [ 0 ] !== '/' ) path = '/' + path ; if ( path [ path . length - 1 ] !== '/' ) path = path + '/' ; return path ; }