add player hasGuessed

This commit is contained in:
2024-12-30 18:36:56 +01:00
parent 22656ba608
commit c1a22098f7
2 changed files with 4 additions and 5 deletions
+2 -2
View File
@@ -2,10 +2,10 @@ export class MessageResponseDTO {
constructor(partial: Partial<MessageResponseDTO>) { constructor(partial: Partial<MessageResponseDTO>) {
this.id = partial.id; this.id = partial.id;
this.value = partial.value; this.value = partial.value;
this.authorId = partial.authorId; if (partial.authorId) this.authorId = partial.authorId;
} }
id: number; id: number;
value: string; value: string;
authorId: string; authorId?: string;
} }
+2 -3
View File
@@ -1,15 +1,14 @@
import { UserResponseDTO } from './userresponse.dto';
export class PlayerResponseDTO { export class PlayerResponseDTO {
constructor(partial: Partial<PlayerResponseDTO>) { constructor(partial: Partial<PlayerResponseDTO>) {
this.score = partial.score; this.score = partial.score;
this.userId = partial.userId; this.userId = partial.userId;
this.id = partial.id; this.id = partial.id;
this.hasGuessed = partial.hasGuessed;
// this.user = new UserResponseDTO(partial.user); // this.user = new UserResponseDTO(partial.user);
} }
id: number; id: number;
userId: string; userId: string;
score: number; score: number;
hasGuessed: boolean;
} }