Merge pull request #112969 from ashwinvbs/bugfix

Fix bug where optional argument is not validated before use
This commit is contained in:
Thaddeus Crews 2025-11-20 11:10:49 -06:00
commit a79b155298
No known key found for this signature in database
GPG key ID: 8C6E5FEB5FC03CCC

View file

@ -1554,7 +1554,9 @@ Ref<Resource> ResourceFormatLoaderJSON::load(const String &p_path, const String
}
if (!FileAccess::exists(p_path)) {
*r_error = ERR_FILE_NOT_FOUND;
if (r_error) {
*r_error = ERR_FILE_NOT_FOUND;
}
return Ref<Resource>();
}