Skip to content

Commit

Permalink
Disabled partial-match search results for short WB-ID-like search pat…
Browse files Browse the repository at this point in the history
…terns with 0 digits #324
  • Loading branch information
mluypaert committed Aug 18, 2023
1 parent 4046240 commit fa58c2c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/wormbase/names/entity.clj
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@
[search-pattern & {:keys [min-chars-match
id-pattern]
:or {min-chars-match 7
id-pattern #"WB[a-zA-Z]+(\d+)"}}]
id-pattern #"WB[a-zA-Z]+(\d*)"}}]
(when-let [[_ numbers] (re-find id-pattern search-pattern)]
(when (< (count numbers) min-chars-match)
(format
Expand Down

0 comments on commit fa58c2c

Please sign in to comment.