Merge pull request #21540 from YeldhamDev/image_reimp_error_fix
Fix error when reimporting an Image resource
This commit is contained in:
commit
bcc50de2d1
|
@ -1479,12 +1479,16 @@ void EditorFileSystem::_reimport_file(const String &p_file) {
|
||||||
cf.instance();
|
cf.instance();
|
||||||
Error err = cf->load(p_file + ".import");
|
Error err = cf->load(p_file + ".import");
|
||||||
if (err == OK) {
|
if (err == OK) {
|
||||||
List<String> sk;
|
if (cf->has_section("params")) {
|
||||||
cf->get_section_keys("params", &sk);
|
List<String> sk;
|
||||||
for (List<String>::Element *E = sk.front(); E; E = E->next()) {
|
cf->get_section_keys("params", &sk);
|
||||||
params[E->get()] = cf->get_value("params", E->get());
|
for (List<String>::Element *E = sk.front(); E; E = E->next()) {
|
||||||
|
params[E->get()] = cf->get_value("params", E->get());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (cf->has_section("remap")) {
|
||||||
|
importer_name = cf->get_value("remap", "importer");
|
||||||
}
|
}
|
||||||
importer_name = cf->get_value("remap", "importer");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue