Fixed updating of objects as well as markDirty and markDeleted.