From f30a9ae27cc449461f5fe63958e4528b00b0f833 Mon Sep 17 00:00:00 2001 From: Clayton Wilson Date: Fri, 6 Dec 2019 12:07:36 -0500 Subject: [PATCH] Fix merge errors, but posts are not displaying on home.js --- twistter-frontend/src/pages/Home.js | 114 ++++++++++++++-------------- 1 file changed, 55 insertions(+), 59 deletions(-) diff --git a/twistter-frontend/src/pages/Home.js b/twistter-frontend/src/pages/Home.js index d635587..4032ed0 100644 --- a/twistter-frontend/src/pages/Home.js +++ b/twistter-frontend/src/pages/Home.js @@ -142,67 +142,63 @@ class Home extends Component { console.log(hiddenBool); let postMarkup = this.state.posts ? ( // <<<<<<< admin-delete - this.state.posts.map(post => post.hidden ? null : - this.state.following ? - this.state.following.includes(post.userHandle) ? ( - - - - {/* { - this.state.imageUrl ? () : - () - } */} - { - post.profileImage ? () : - () - } - - {post.userHandle} - {this.formatDate(post.createdAt)} -
- {post.microBlogTitle} - {post.quoteBody} -
- {post.body} -
- Topics: {post.microBlogTopics.join(", ")} -
- {!hiddenBool && - - } - - Likes {post.likeCount} - {/* */} - - + this.state.posts.map(post => !post.hidden && this.state.following && this.state.following.includes(post.userHandle) ? ( + + + + {/* { + this.state.imageUrl ? () : + () + } */} + { + post.profileImage ? () : + () + } + + {post.userHandle} + {this.formatDate(post.createdAt)} +
+ {post.microBlogTitle} + {post.quoteBody} +
+ {post.body} +
+ Topics: {post.microBlogTopics.join(", ")} +
+ {!hiddenBool && + + } + + Likes {post.likeCount} + {/* */} + + - {/* */} + {/* */} - Likes {post.likeCount} Comments {post.commentCount} - -
-
- ) : ( -

- ) + Likes {post.likeCount} Comments {post.commentCount} + +
+
) : ( -

- ) +

+ ) + ) // ======= // this.state.posts.map(post => // this.state.following ? ( @@ -214,7 +210,7 @@ class Home extends Component { //

// ) // >>>>>>> master - ) + ) : (

Loading post...

);