mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-02-24 16:14:01 +08:00
fix(mail-important): Fix broken specs when getStandardCategory('important') returns null
This commit is contained in:
parent
6c881f4f64
commit
15f5a6899f
1 changed files with 3 additions and 1 deletions
|
@ -32,7 +32,9 @@ class MailImportantIcon extends React.Component
|
|||
render: =>
|
||||
return false unless @state.showing
|
||||
|
||||
importantId = CategoryStore.getStandardCategory('important').id
|
||||
importantId = CategoryStore.getStandardCategory('important')?.id
|
||||
return false unless importantId
|
||||
|
||||
isImportant = _.findWhere(@props.thread.labels, {id: importantId})?
|
||||
|
||||
activeClassname = if isImportant then "active" else ""
|
||||
|
|
Loading…
Reference in a new issue