mirror of
https://github.com/sussy-code/backend.git
synced 2026-04-21 00:42:02 +00:00
Add last logged in to DTO
Co-authored-by: mrjvs <mistrjvs@gmail.com>
This commit is contained in:
parent
fa1880ba48
commit
1ee5cf9ffc
1 changed files with 2 additions and 0 deletions
|
|
@ -41,6 +41,7 @@ export interface UserDTO {
|
||||||
publicKey: string;
|
publicKey: string;
|
||||||
roles: string[];
|
roles: string[];
|
||||||
createdAt: string;
|
createdAt: string;
|
||||||
|
lastLoggedIn?: string;
|
||||||
profile: {
|
profile: {
|
||||||
colorA: string;
|
colorA: string;
|
||||||
colorB: string;
|
colorB: string;
|
||||||
|
|
@ -55,6 +56,7 @@ export function formatUser(user: User): UserDTO {
|
||||||
publicKey: user.publicKey,
|
publicKey: user.publicKey,
|
||||||
roles: user.roles,
|
roles: user.roles,
|
||||||
createdAt: user.createdAt.toISOString(),
|
createdAt: user.createdAt.toISOString(),
|
||||||
|
lastLoggedIn: user.lastLoggedIn?.toISOString(),
|
||||||
profile: {
|
profile: {
|
||||||
colorA: user.profile.colorA,
|
colorA: user.profile.colorA,
|
||||||
colorB: user.profile.colorB,
|
colorB: user.profile.colorB,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue