Skip to content

Commit

Permalink
Merge pull request #1003 from ChuckMoe/returnedUserDto
Browse files Browse the repository at this point in the history
Make `emailVerified` and `realm` optional in ReturnedUserDto #998
  • Loading branch information
nitrosx authored Jan 17, 2024
2 parents 01a7faf + 29af3f6 commit a8fefc3
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/users/dto/returned-user.dto.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { ApiProperty } from "@nestjs/swagger";
import { IsOptional } from "class-validator";

export class ReturnedUserDto {
@ApiProperty({
Expand All @@ -18,13 +19,17 @@ export class ReturnedUserDto {

@ApiProperty({
description: "Email has been verified",
required: false,
})
readonly emailVerified: boolean;
@IsOptional()
readonly emailVerified?: boolean;

@ApiProperty({
description: "Where the info of this user are stored",
required: false,
})
readonly realm: string;
@IsOptional()
readonly realm?: string;

@ApiProperty({
description: "Strategy used to authenticate this user",
Expand Down

0 comments on commit a8fefc3

Please sign in to comment.