Skip to content

Commit

Permalink
Optimize search time (#959)
Browse files Browse the repository at this point in the history
  • Loading branch information
atuchin-m authored Jun 5, 2024
1 parent 0ce599e commit 2cc1413
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/study_processor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ export class StudyFilter {
}

matches(s: ProcessedStudy): boolean {
if (s.getPriority() < this.minPriority) return false;
if (s.studyDetails.isOutdated() && !this.includeOutdated) return false;
const regex = this.searchRegexp;
if (regex !== undefined) {
let found = false;
Expand All @@ -80,8 +82,6 @@ export class StudyFilter {
if (!found) return false;
}

if (s.getPriority() < this.minPriority) return false;
if (s.studyDetails.isOutdated() && !this.includeOutdated) return false;
return true;
}
}
Expand Down

0 comments on commit 2cc1413

Please sign in to comment.