Skip to content
Snippets Groups Projects
Commit 65a71fad authored by Hugo SUBTIL's avatar Hugo SUBTIL
Browse files

fix(news): change map for foreach

parent bce0381e
No related branches found
No related tags found
2 merge requests!178release V1.10.0,!111Dev
......@@ -17,7 +17,7 @@ export class PostService {
public getPost(idPost: string): Observable<PostWithMeta> {
return this.http.get<PostWithMeta>(`${this.baseUrl}/` + idPost).pipe(
map((item: PostWithMeta) => {
item.posts.map((post) => this.addAuthorToPost(post));
item.posts.forEach((post) => this.addAuthorToPost(post));
return new PostWithMeta(item);
})
);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment