diff options
author | A Thousand Ships <96648715+AThousandShips@users.noreply.github.com> | 2024-05-06 16:20:20 +0200 |
---|---|---|
committer | A Thousand Ships <96648715+AThousandShips@users.noreply.github.com> | 2024-05-08 12:37:42 +0200 |
commit | a0dbdcc3abbd3e6307c6e68d0e60f8c0fa31d576 (patch) | |
tree | 0b8d0a36f69e28096b06956ebbe2c5e6f7e403a3 /editor/editor_help_search.cpp | |
parent | 281fe39929303a8ef12e72ff7999b849bbe0678d (diff) | |
download | redot-engine-a0dbdcc3abbd3e6307c6e68d0e60f8c0fa31d576.tar.gz |
Replace `find` with `contains/has` where applicable
* Replaces `find(...) != -1` with `contains` for `String`
* Replaces `find(...) == -1` with `!contains` for `String`
* Replaces `find(...) != -1` with `has` for containers
* Replaces `find(...) == -1` with `!has` for containers
Diffstat (limited to 'editor/editor_help_search.cpp')
-rw-r--r-- | editor/editor_help_search.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editor/editor_help_search.cpp b/editor/editor_help_search.cpp index ff381d68c0..02b5146052 100644 --- a/editor/editor_help_search.cpp +++ b/editor/editor_help_search.cpp @@ -744,7 +744,7 @@ String EditorHelpSearch::Runner::_match_keywords_in_all_terms(const String &p_ke bool EditorHelpSearch::Runner::_match_string(const String &p_term, const String &p_string) const { if (search_flags & SEARCH_CASE_SENSITIVE) { - return p_string.find(p_term) > -1; + return p_string.contains(p_term); } else { return p_string.findn(p_term) > -1; } |