Fixed deleting object.