mirror of https://github.com/Chocobozzz/PeerTube
Client: fix compilation about the user created date
parent
c53d2a4e5e
commit
44c5275e1b
|
@ -4,11 +4,14 @@ export class User {
|
||||||
role: string;
|
role: string;
|
||||||
createdDate: Date;
|
createdDate: Date;
|
||||||
|
|
||||||
constructor(hash: { id: string, username: string, role: string, createdDate: Date }) {
|
constructor(hash: { id: string, username: string, role: string, createdDate?: Date }) {
|
||||||
this.id = hash.id;
|
this.id = hash.id;
|
||||||
this.username = hash.username;
|
this.username = hash.username;
|
||||||
this.role = hash.role;
|
this.role = hash.role;
|
||||||
this.createdDate = hash.createdDate;
|
|
||||||
|
if (hash.createdDate) {
|
||||||
|
this.createdDate = hash.createdDate;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
isAdmin() {
|
isAdmin() {
|
||||||
|
|
Loading…
Reference in New Issue