bugfix when re-adding an object