Skip to content

Commit 25a28ed

Browse files
Apply suggestions from code review
Co-authored-by: Vir Desai <virdesai@users.noreply.github.com>
1 parent 4a2870f commit 25a28ed

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/components/Attachment/Attachment.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ const Attachment = (props) => {
3434
return null;
3535
}
3636

37-
const Giphy = props.Giphy || Card;
38-
const UrlPreview = props.UrlPreview || Card;
37+
const Giphy = props && props.Giphy ? props.Giphy : Card;
38+
const UrlPreview = props && props.UrlPreview ? props.UrlPreview : Card;
3939
const cardProps = {
4040
Header: CardHeader ? CardHeader : undefined,
4141
Cover: CardCover ? CardCover : undefined,

0 commit comments

Comments
 (0)