fixed error if object doesn't exist