Skip to content

Commit

Permalink
use const for min seqs in tree
Browse files Browse the repository at this point in the history
  • Loading branch information
bobular committed Nov 6, 2024
1 parent 2fa75aa commit 7ef7b0e
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@ export function RecordTable_Sequences(

const treeResponse = useOrthoService(
(orthoService) => {
if (numSequences < 3) return Promise.resolve(undefined);
if (numSequences < MIN_SEQUENCES_FOR_TREE)
return Promise.resolve(undefined);
return orthoService.getGroupTree(groupName);
},
[groupName, numSequences]
Expand Down Expand Up @@ -403,7 +404,7 @@ export function RecordTable_Sequences(
}

if (
numSequences >= 3 &&
numSequences >= MIN_SEQUENCES_FOR_TREE &&
mesaRows != null &&
sortedRows != null &&
(mesaRows.length !== sortedRows.length ||
Expand Down Expand Up @@ -637,7 +638,7 @@ export function RecordTable_Sequences(
if (filteredRows == null) return null;

const warningText =
numSequences >= 3 &&
numSequences >= MIN_SEQUENCES_FOR_TREE &&
(filteredRows.length > MAX_SEQUENCES_FOR_TREE ||
filteredRows.length < MIN_SEQUENCES_FOR_TREE) ? (
<span>
Expand Down

0 comments on commit 7ef7b0e

Please sign in to comment.