From 5b90ac638e3e589edd17380376e992301bcca1a1 Mon Sep 17 00:00:00 2001 From: Max Date: Mon, 13 Jan 2020 19:22:05 +0100 Subject: [PATCH] post is visible immediately --- src/app/services/feed/feed.service.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/app/services/feed/feed.service.ts b/src/app/services/feed/feed.service.ts index 3867512..6e94178 100644 --- a/src/app/services/feed/feed.service.ts +++ b/src/app/services/feed/feed.service.ts @@ -49,6 +49,7 @@ export class FeedService { const updatedposts = this.newPosts.getValue(); updatedposts.unshift(this.renderPost(response.json())); this.newPosts.next(updatedposts); + this.posts.next(this.newPosts.getValue()); }); } @@ -84,6 +85,7 @@ export class FeedService { const updatedposts = this.newPosts.getValue(); updatedposts.unshift(this.renderPost(response.json())); this.newPosts.next(updatedposts); + this.posts.next(this.newPosts.getValue()); }); }