about summary refs log tree commit diff
path: root/app/javascript
diff options
context:
space:
mode:
authorClaire <claire.github-309c@sitedethib.com>2022-11-11 21:23:03 +0100
committerClaire <claire.github-309c@sitedethib.com>2022-11-12 14:02:23 +0100
commita808ac1fd8d4a42ee930bbb30cb6b58c810f828b (patch)
tree5cdf443e718788f8473148ce4d4205da54efbf04 /app/javascript
parent9255bfb908f660889f54d4fd5ea92279b09d8cd1 (diff)
[Glitch] Fix WebUI crash when listing server blocks and rationale is not available
Port 93a6ebc83d4bc6647d1eafce509a29aa3642c87c to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
Diffstat (limited to 'app/javascript')
-rw-r--r--app/javascript/flavours/glitch/features/about/index.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/javascript/flavours/glitch/features/about/index.js b/app/javascript/flavours/glitch/features/about/index.js
index f97eb64b4..57f295ea9 100644
--- a/app/javascript/flavours/glitch/features/about/index.js
+++ b/app/javascript/flavours/glitch/features/about/index.js
@@ -191,7 +191,7 @@ class About extends React.PureComponent {
                         <span className='about__domain-blocks__domain__type' title={intl.formatMessage(severityMessages[block.get('severity')].explanation)}>{intl.formatMessage(severityMessages[block.get('severity')].title)}</span>
                       </div>
 
-                      <p>{block.get('comment').length > 0 ? block.get('comment') : <FormattedMessage id='about.domain_blocks.no_reason_available' defaultMessage='Reason not available' />}</p>
+                      <p>{(block.get('comment') || '').length > 0 ? block.get('comment') : <FormattedMessage id='about.domain_blocks.no_reason_available' defaultMessage='Reason not available' />}</p>
                     </div>
                   ))}
                 </div>