Skip to content
This repository was archived by the owner on Jul 22, 2025. It is now read-only.

DEV: Prevent HyDE search from being called multiple times #422

Merged
merged 1 commit into from
Jan 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -124,15 +124,17 @@ export default class SemanticSearch extends Component {
this.preventAISearch = false;
}

if (this.initialSearchTerm) {
if (this.initialSearchTerm && !this.searching) {
return this.performHyDESearch();
}

this.resetAIResults();

withPluginApi("1.15.0", (api) => {
api.onAppEvent("full-page-search:trigger-search", () => {
return this.performHyDESearch();
if (!this.searching) {
return this.performHyDESearch();
}
});
});
}
Expand Down