Merge pull request #109433 from KoBeWi/hastension

Add `has_extension()` method to String
This commit is contained in:
Thaddeus Crews 2025-10-31 09:23:30 -05:00
commit ae9732139a
No known key found for this signature in database
GPG key ID: 8C6E5FEB5FC03CCC
29 changed files with 46 additions and 48 deletions

View file

@ -1521,7 +1521,7 @@ Error EditorExportPlatform::export_project_files(const Ref<EditorExportPreset> &
// Just store it as it comes.
// Customization only happens if plugins did not take care of it before.
bool force_binary = convert_text_to_binary && (path.get_extension().to_lower() == "tres" || path.get_extension().to_lower() == "tscn");
bool force_binary = convert_text_to_binary && (path.has_extension("tres") || path.has_extension("tscn"));
String export_path = _export_customize(path, customize_resources_plugins, customize_scenes_plugins, export_cache, export_base_path, force_binary);
if (export_path != path) {