diff --git a/src/pyj/read_book/find.pyj b/src/pyj/read_book/find.pyj index 03ea74f69d..fa000f9ad5 100644 --- a/src/pyj/read_book/find.pyj +++ b/src/pyj/read_book/find.pyj @@ -79,7 +79,7 @@ def find_specific_occurrence(q, num, before_len, after_len, text_map): break match_num += 1 from_idx = idx + 1 - if num < match_num: + if match_num < num: continue start_node, start_offset, node_pos = find_node_for_index_binary(text_map.node_list, idx + before_len, pos) if start_node is not None: