wip
This commit is contained in:
@@ -16,7 +16,7 @@ export interface SponsorAccountProps {
|
||||
passwordHash: string;
|
||||
companyName: string;
|
||||
isActive: boolean;
|
||||
createdAt: Date;
|
||||
createdAt?: Date;
|
||||
lastLoginAt?: Date;
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ export class SponsorAccount {
|
||||
this.passwordHash = props.passwordHash;
|
||||
this.companyName = props.companyName;
|
||||
this.isActive = props.isActive;
|
||||
this.createdAt = props.createdAt;
|
||||
this.createdAt = props.createdAt ?? new Date();
|
||||
this.lastLoginAt = props.lastLoginAt;
|
||||
}
|
||||
|
||||
@@ -128,7 +128,7 @@ export class SponsorAccount {
|
||||
companyName: this.companyName,
|
||||
isActive: false,
|
||||
createdAt: this.createdAt,
|
||||
lastLoginAt: this.lastLoginAt,
|
||||
...(this.lastLoginAt ? { lastLoginAt: this.lastLoginAt } : {}),
|
||||
});
|
||||
}
|
||||
|
||||
@@ -145,7 +145,7 @@ export class SponsorAccount {
|
||||
companyName: this.companyName,
|
||||
isActive: this.isActive,
|
||||
createdAt: this.createdAt,
|
||||
lastLoginAt: this.lastLoginAt,
|
||||
...(this.lastLoginAt ? { lastLoginAt: this.lastLoginAt } : {}),
|
||||
});
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user