Skip to content

Commit

Permalink
Merge pull request godotengine#102213 from KoBeWi/ensure_path_ensures…
Browse files Browse the repository at this point in the history
…_less_bugs_I_guess

Fix save path validation for imported scenes
  • Loading branch information
Repiteo committed Jan 31, 2025
2 parents fe77e5e + 06b2c9f commit 4f56d0d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions editor/import/3d/resource_importer_scene.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2877,8 +2877,7 @@ Error ResourceImporterScene::_check_resource_save_paths(const Dictionary &p_data
const Dictionary &settings = p_data[keys[i]];

if (bool(settings.get("save_to_file/enabled", false)) && settings.has("save_to_file/path")) {
const String &save_path = settings["save_to_file/path"];

const String save_path = ResourceUID::ensure_path(settings["save_to_file/path"]);
ERR_FAIL_COND_V(!save_path.is_empty() && !DirAccess::exists(save_path.get_base_dir()), ERR_FILE_BAD_PATH);
}
}
Expand Down

0 comments on commit 4f56d0d

Please sign in to comment.