mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-09-28 15:35:37 +08:00
fix(sheet-toolbar): Make robust against mail view null names (Sentry 3861)
This commit is contained in:
parent
408e96945c
commit
86fc3a4c2b
1 changed files with 2 additions and 2 deletions
|
@ -44,11 +44,11 @@ class ToolbarBack extends React.Component
|
|||
CategoryStore ?= require './flux/stores/category-store'
|
||||
FocusedMailViewStore ?= require './flux/stores/focused-mail-view-store'
|
||||
@state =
|
||||
categoryName: FocusedMailViewStore.mailView().name
|
||||
categoryName: FocusedMailViewStore.mailView()?.name
|
||||
|
||||
componentDidMount: =>
|
||||
@_unsubscriber = FocusedMailViewStore.listen =>
|
||||
@setState(categoryName: FocusedMailViewStore.mailView().name)
|
||||
@setState(categoryName: FocusedMailViewStore.mailView()?.name)
|
||||
|
||||
componentWillUnmount: =>
|
||||
@_unsubscriber() if @_unsubscriber
|
||||
|
|
Loading…
Add table
Reference in a new issue