How to set NavMeshAgent.SetDestination to GameObject's position

,I want to pick a random point in an array of points and have a zombie walk there. I need to use GameObject to find all the nav points but, the NavMeshAgent needs transforms. What’s the magic words?

private void Wander()
	{
		if (wandering == false)
		{
			wandering = true;
			GameObject[] travelPoints = GameObject.FindGameObjectsWithTag("Nav");
			travelPoint = Random.Range(0, travelPoints.Length);
        }

		nav.SetDestination(travelPoints[travelPoint].transform.position);

		
	}

Does anybody look at these posts? I figured it out

        if (wandering == false)
        {
            wandering = true;
            NavPoint = Random.Range(0, NavPoints.Length);
            target = NavPoints[NavPoint].gameObject.transform;
        }
		nav.SetDestination(target.position);