Partial fix for objects not being cleaned up when they should. There's more left