mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-14 23:24:46 -04:00
refactor(note-metadata): do not embed User objects
This is part of an effort to consistently not embed User objects in API responses. Usernames are returned instead. Signed-off-by: David Mehren <git@herrmehren.de>
This commit is contained in:
parent
96ed5f3cc8
commit
08f97209ec
5 changed files with 8 additions and 11 deletions
|
@ -77,10 +77,10 @@ export class NoteMetadataDto {
|
|||
/**
|
||||
* User that last edited the note
|
||||
*/
|
||||
@ValidateNested()
|
||||
@ApiPropertyOptional({ type: UserInfoDto })
|
||||
@IsString()
|
||||
@ApiPropertyOptional()
|
||||
@IsOptional()
|
||||
updateUser: UserInfoDto | null;
|
||||
updateUsername: string | null;
|
||||
|
||||
/**
|
||||
* Counts how many times the published note has been viewed
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue