Search: Fix report search usage from throwing in console (#60382)

This commit is contained in:
Josh Hunt 2022-12-15 13:58:20 +00:00 committed by GitHub
parent 8d5b19bc61
commit ecf83a6df9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -239,7 +239,7 @@ export class SearchStateManager extends StateManagerBase<SearchState> {
/**
* Caller should handle debounce
*/
onReportSearchUsage() {
onReportSearchUsage = () => {
reportDashboardListViewed(this.state.eventTrackingNamespace, {
layout: this.state.layout,
starred: this.state.starred,
@ -248,7 +248,7 @@ export class SearchStateManager extends StateManagerBase<SearchState> {
tagCount: this.state.tag?.length,
includePanels: this.state.includePanels,
});
}
};
}
let stateManager: SearchStateManager;