Skip to content

Commit

Permalink
Minor
Browse files Browse the repository at this point in the history
  • Loading branch information
vmonakhov committed Feb 7, 2025
1 parent 65033cb commit 34e3239
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/components/CognateAnalysisModal/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2410,9 +2410,9 @@ class CognateAnalysisModal extends React.Component {
}
} else if (this.props.mode === "neuro_suggestions" || this.props.mode === "multi_neuro_suggestions") {

const { truth_threshold } = this.state;
const truthThreshold = parseFloat(this.state.truthThreshold);

if (typeof truth_threshold !== 'number' || truth_threshold < 0.7 || truth_threshold > 0.999) {
if (!truthThreshold || truthThreshold < 0.7 || truthThreshold > 0.999) {
window.logger.err(this.context("Truth threshold must be between 0,7 and 0,999"));
this.setState({ computing: false });
return;
Expand Down Expand Up @@ -2475,7 +2475,7 @@ class CognateAnalysisModal extends React.Component {
matchTranslations: this.state.matchTranslationsFlag,
sourcePerspectiveId: perspectiveId,
baseLanguageId: this.baseLanguageId,
truthThreshold: this.state.truthThreshold,
truthThreshold,
perspectiveInfoList,
stamp: start
}
Expand Down

0 comments on commit 34e3239

Please sign in to comment.