From c86f8aa3877095927938a3ec2e5642e183f77112 Mon Sep 17 00:00:00 2001 From: Evan Morikawa Date: Mon, 11 Jul 2016 18:16:08 -0700 Subject: [PATCH] feat(analytics): add Sidebar Opened & Sidebar Closed events --- src/flux/stores/workspace-store.coffee | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/flux/stores/workspace-store.coffee b/src/flux/stores/workspace-store.coffee index 790593e7b..09defff05 100644 --- a/src/flux/stores/workspace-store.coffee +++ b/src/flux/stores/workspace-store.coffee @@ -103,8 +103,12 @@ class WorkspaceStore extends NylasStore throw new Error("Actions.toggleWorkspaceLocationHidden - pass a WorkspaceStore.Location") if @_hiddenLocations[location.id] + if location is @Location.MessageListSidebar + Actions.recordUserEvent("Sidebar Opened") delete @_hiddenLocations[location.id] else + if location is @Location.MessageListSidebar + Actions.recordUserEvent("Sidebar Closed") @_hiddenLocations[location.id] = location NylasEnv.config.set('core.workspace.hiddenLocations', @_hiddenLocations)