diff options
Diffstat (limited to 'webui/src/Author.js')
-rw-r--r-- | webui/src/Author.js | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/webui/src/Author.js b/webui/src/Author.js index 0ad7e257..7285ed4b 100644 --- a/webui/src/Author.js +++ b/webui/src/Author.js @@ -1,6 +1,6 @@ +import { withStyles } from '@material-ui/core/styles'; import Tooltip from '@material-ui/core/Tooltip/Tooltip'; import React from 'react'; -import { withStyles } from '@material-ui/core/styles'; const styles = theme => ({ author: { @@ -14,9 +14,13 @@ const styles = theme => ({ const Author = ({ author, bold, classes }) => { const klass = bold ? [classes.author, classes.bold] : [classes.author]; + if (!author.email) { + return <span className={klass.join(' ')}>{author.displayName}</span>; + } + return ( <Tooltip title={author.email}> - <span className={klass.join(' ')}>{author.name}</span> + <span className={klass.join(' ')}>{author.displayName}</span> </Tooltip> ); }; |