diff --git a/src/packages/command-panel/lib/command-panel.coffee b/src/packages/command-panel/lib/command-panel.coffee index 1159e9ce4..43291ef80 100644 --- a/src/packages/command-panel/lib/command-panel.coffee +++ b/src/packages/command-panel/lib/command-panel.coffee @@ -3,15 +3,12 @@ CommandPanelView = require './command-panel-view' module.exports = commandPanelView: null - activate: (@state) -> - @commandPanelView = new CommandPanelView(@state) + activate: (state) -> + @commandPanelView = new CommandPanelView(state) deactivate: -> @commandPanelView?.destroy() @commandPanelView = null serialize: -> - if @commandPanelView? - @commandPanelView.serialize() - else - @state + @commandPanelView.serialize()