Skip to content

Commit

Permalink
fix: orm nullable 명시
Browse files Browse the repository at this point in the history
  • Loading branch information
Me1e committed Dec 28, 2023
1 parent fc1e298 commit 57758cb
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions libs/entity/user/user.entity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,17 @@ export class User {
@Column({ length: 20 })
nickname!: string;

@ApiProperty({ nullable: true })
@ApiProperty()
@IsDate()
@Column()
@Column({ nullable: true })
birth?: Date;

@ApiProperty({ enum: SexEnum, nullable: true })
@ApiProperty({ enum: SexEnum })
@IsEnum(SexEnum)
@Column({
type: 'enum',
enum: SexEnum,
nullable: true,
})
sex?: SexEnum;

Expand Down

0 comments on commit 57758cb

Please sign in to comment.