1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-07 12:30:27 +00:00

[Core] Add case-insensitive String::containsn

This commit is contained in:
A Thousand Ships
2024-05-06 10:26:10 +02:00
parent 281fe39929
commit b4c6cc7d82
23 changed files with 64 additions and 32 deletions

View File

@@ -50,7 +50,7 @@ private:
if (p_path.contains("\\")) {
String project_path = ProjectSettings::get_singleton()->get_resource_path();
String path = p_path.replace("\\", "/");
return path.findn(project_path) != -1;
return path.containsn(project_path);
}
return p_path.begins_with(ProjectSettings::get_singleton()->get_resource_path());
}