• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

ckapps / overckd / 13656842746

31 May 2023 01:52PM UTC coverage: 20.328%. First build
13656842746

push

github

web-flow
Merge pull request #17 from ckapps/chore/update-deps

Chore/update deps

32 of 288 branches covered (11.11%)

Branch coverage included in aggregate %.

32 of 270 new or added lines in 73 files covered. (11.85%)

464 of 2152 relevant lines covered (21.56%)

0.76 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/packages/server/src/core/search/transform-from-request-property.operator.ts
1
import { HttpRequest } from '@marblejs/http';
2
import { unflattenQuery } from '@overckd/domain-rx/dist/search';
×
3
import { DataQuery } from '@overckd/domain/dist/search';
4
import { OperatorFunction } from 'rxjs';
NEW
5
import { map } from 'rxjs/operators';
×
NEW
6
import { FromQueryString, mapPaginationTyped } from '../pagination';
×
7

8
/**
9
 * Utility function for transform from request properties
10
 *
11
 * @param property Property to extract information from
12
 *
13
 * @returns
14
 */
15
export function transformFromRequestProperty<
×
16
  TBody = unknown,
17
  TParams = unknown,
18
  TQuery extends Record<string, unknown> = Record<string, unknown>,
19
>(
20
  property: 'query',
21
): OperatorFunction<
22
  HttpRequest<TBody, TParams, FromQueryString<TQuery>>,
23
  DataQuery<TQuery>
24
> {
25
  return obs$ =>
×
26
    obs$.pipe(
×
27
      // Extract the requested property
NEW
28
      map(value => value?.[property]),
×
29
      // Map pagination information
30
      mapPaginationTyped(),
31
      // Unwrap
32
      // eslint-disable-next-line @typescript-eslint/ban-ts-comment
33
      // @ts-ignore
34
      map<unknown, DataQuery<TQuery>>(unflattenQuery),
35
    );
36
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc