Enhance error handling and improve script tracking in RojoTree and ServeSession

- Added a test to verify the functionality of script tracking updates in RojoTree, ensuring proper addition and removal of script references.
- Improved error handling in ServeSession by clearing temporary script IDs upon disconnection to prevent potential memory leaks.
- Updated API logic to filter out empty properties and children during instance addition, enhancing the integrity of the synchronization process.

These changes aim to optimize script management and enhance the robustness of the session handling and tree operations.
This commit is contained in:
Joe 2026-02-28 11:16:10 -06:00
parent 9d6b48a53e
commit ec51c14a41
5 changed files with 33 additions and 79 deletions

View file

@ -1020,6 +1020,7 @@ end
function ServeSession:__stopInternal(err)
self:__setStatus(Status.Disconnected, err)
self.__apiContext:disconnect()
table.clear(self.__instanceMap.scriptsOnlyTempIds)
self.__instanceMap:stop()
self.__changeBatcher:stop()