|
|
@ -134,9 +134,9 @@ export class ProfileService {
|
|
|
|
const userVote: string = post.userVote;
|
|
|
|
const userVote: string = post.userVote;
|
|
|
|
const deletable: boolean = post.deletable;
|
|
|
|
const deletable: boolean = post.deletable;
|
|
|
|
const author = new Author(post.author.id, post.author.name, post.author.handle);
|
|
|
|
const author = new Author(post.author.id, post.author.name, post.author.handle);
|
|
|
|
const temp = new Date(Number(post.createdAt));
|
|
|
|
const ptemp = new Date(Number(post.createdAt));
|
|
|
|
const date = temp.toLocaleString('en-GB');
|
|
|
|
const pdate = ptemp.toLocaleString('en-GB');
|
|
|
|
posts.push(new Post(id, content, htmlContent, upvotes, downvotes, userVote, deletable, date, author));
|
|
|
|
posts.push(new Post(id, content, htmlContent, upvotes, downvotes, userVote, deletable, pdate, author));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
profile.posts = posts;
|
|
|
|
profile.posts = posts;
|
|
|
|
console.log(profile);
|
|
|
|
console.log(profile);
|
|
|
|