File tree Expand file tree Collapse file tree 2 files changed +2
-6
lines changed Expand file tree Collapse file tree 2 files changed +2
-6
lines changed Original file line number Diff line number Diff line change 1
1
import { applyDecorators } from '@nestjs/common' ;
2
2
import { Field } from '@nestjs/graphql' ;
3
- import { Transform , Type } from 'class-transformer' ;
3
+ import { Type } from 'class-transformer' ;
4
4
import { ValidateNested } from 'class-validator' ;
5
5
import { Constructor , HasRequiredKeys } from 'type-fest' ;
6
- import { DefaultValue } from './default-value' ;
7
6
import { AbstractClassType } from './types' ;
8
7
9
8
/**
@@ -28,6 +27,4 @@ export const FilterField = <T extends object>(
28
27
] ) ,
29
28
Type ( type ) ,
30
29
ValidateNested ( ) ,
31
- DefaultValue . Set ( { } ) , // Default when omitted
32
- Transform ( ( { value } ) => value || { } ) , // null -> {}
33
30
) ;
Original file line number Diff line number Diff line change @@ -4,7 +4,6 @@ import { setHas } from '@seedcompany/common';
4
4
import { Matches , Max , Min } from 'class-validator' ;
5
5
import { stripIndent } from 'common-tags' ;
6
6
import { DataObject } from './data-object' ;
7
- import { DefaultValue } from './default-value' ;
8
7
import { Order } from './order.enum' ;
9
8
import { AbstractClassType } from './types' ;
10
9
@@ -126,7 +125,7 @@ export const ListArg = <T extends PaginationInput>(
126
125
name : 'input' ,
127
126
type : ( ) => input ,
128
127
nullable : true ,
129
- defaultValue : DataObject . defaultValue ( input , DefaultValue . Get ( input ) ) ,
128
+ defaultValue : DataObject . defaultValue ( input ) ,
130
129
...opts ,
131
130
} ,
132
131
...pipes ,
You can’t perform that action at this time.
0 commit comments