Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- jsonignore
- Swagger
- java.lang.nosuchmethoderror
- bytebuddyinterceptor
- websecurityconfiguration
- springboot
Archives
- Today
- Total
NOT FOUND
class-validator nullable에 사용할 때 주의할 점 본문
@MaxLength(10)
filed: string | null
위 상황에서 "filed": null로 요청을 보냈을 때 BadRequest가 떨어졌다. 난 최대값만 제한했을 뿐인데 이게 뭔가 했었다.
@MaxLength(10) @IsOptional()
filed: string | null
@IsOptional()을 추가해주고 해결했다.
'nest js' 카테고리의 다른 글
nest js jwt error : secretOrPrivateKey must have a value (0) | 2022.09.21 |
---|