Browse Source

Fixes #47607 (forgotten statement in GDNative cleanup)

Co-authored-by: geekrelief <[email protected]>
(cherry picked from commit 0fe851da23050c28e85ba4165b24d603c8c3b382)
Jan Haller 4 năm trước cách đây
mục cha
commit
f64d9423a5
1 tập tin đã thay đổi với 2 bổ sung0 xóa
  1. 2 0
      modules/gdnative/nativescript/nativescript.cpp

+ 2 - 0
modules/gdnative/nativescript/nativescript.cpp

@@ -1534,6 +1534,8 @@ void NativeScriptLanguage::unregister_script(NativeScript *script) {
 						C->get().destroy_func.free_func(C->get().destroy_func.method_data);
 					}
 				}
+
+				library_classes.erase(script->lib_path);
 			}
 
 			Map<String, Ref<GDNative> >::Element *G = library_gdnatives.find(script->lib_path);