Send tracks event when adding dashboard section.

This commit is contained in:
Jeff Stieler 2019-07-10 16:52:15 -06:00
parent 29a46f0665
commit 314e6d90e0
1 changed files with 3 additions and 1 deletions

View File

@ -103,7 +103,9 @@ class CustomizableDashboard extends Component {
toggledSection.isVisible = ! toggledSection.isVisible;
sections.push( toggledSection );
if ( ! toggledSection.isVisible ) {
if ( toggledSection.isVisible ) {
recordEvent( 'dash_section_add', { key: toggledSection.key } );
} else {
recordEvent( 'dash_section_remove', { key: toggledSection.key } );
}