From 3b33b51f11349ba7fd22f9ce39d7fd1879670aa5 Mon Sep 17 00:00:00 2001 From: Harrison Healey Date: Thu, 3 May 2018 10:02:09 -0400 Subject: [PATCH] MM-10360 Render OpenGraph previews for pages with an empty description (#1651) * MM-10360 Render OpenGraph previews for pages with an empty description * Updated mattermost-redux --- .../post_attachment_opengraph.js | 22 ++++++++++--------- package-lock.json | 2 +- package.json | 2 +- 3 files changed, 14 insertions(+), 12 deletions(-) diff --git a/app/components/post_attachment_opengraph/post_attachment_opengraph.js b/app/components/post_attachment_opengraph/post_attachment_opengraph.js index 2b99dcc3e..3a96929cc 100644 --- a/app/components/post_attachment_opengraph/post_attachment_opengraph.js +++ b/app/components/post_attachment_opengraph/post_attachment_opengraph.js @@ -217,7 +217,7 @@ export default class PostAttachmentOpenGraph extends PureComponent { const {isReplyPost, openGraphData, theme} = this.props; const {hasImage, height, imageUrl, width} = this.state; - if (!openGraphData || !openGraphData.description) { + if (!openGraphData || openGraphData.description == null) { return null; } @@ -248,15 +248,17 @@ export default class PostAttachmentOpenGraph extends PureComponent { - - - {openGraphData.description} - - + {openGraphData.description && + + + {openGraphData.description} + + + } {hasImage &&