From a6344d8e717f5e83d13dc30bd1fbb7f66bc26e49 Mon Sep 17 00:00:00 2001 From: Wyatt Johnson Date: Tue, 17 Apr 2018 13:19:03 -0600 Subject: [PATCH] fixed proptype missing validation --- .../src/components/Embed.js | 23 +++++++++++-------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/client/coral-embed-stream/src/components/Embed.js b/client/coral-embed-stream/src/components/Embed.js index cb4803a2d..a2476527e 100644 --- a/client/coral-embed-stream/src/components/Embed.js +++ b/client/coral-embed-stream/src/components/Embed.js @@ -16,8 +16,6 @@ import cn from 'classnames'; export default class Embed extends React.Component { getTabs() { - if (!this.props.currentUser) return false; - const tabs = [ {t('embed_comments_tab')} , - - {t('framework.my_profile')} - , ]; + + if (this.props.currentUser) { + tabs.push( + + {t('framework.my_profile')} + + ); + } + if (can(this.props.currentUser, 'UPDATE_ASSET_CONFIG')) { tabs.push( ); } + return tabs; }