Get tag of component parent

How do I get the tag of a component’s parent? This is my script, focusing on lines 9 and 14.

	public void Overview(){
		Debug.Log ("start overview");
		foreach (GameObject player in GameObject.FindGameObjectsWithTag("Player")){
			Debug.Log ("start foreach 1");
			if (player.GetComponent<Renderer>().material.GetColor("_Color") =={
				Debug.Log ("start if 1");
				foreach (Camera cam in player.GetComponentsInChildren<Camera>()) {
					Debug.Log ("start foreach 2");
					if (cam.gameObject.tag == "MainCamera") {
						Debug.Log ("start if 2");
						Debug.Log ("set main cam");
						Main_Cam = cam;
						Debug.Log ("end if");
					} else if (cam.gameObject.tag == "SpectateCamera") {
						Debug.Log ("Start elif 1");
						Debug.Log ("set specctate cam");
						Spectate_Cam = cam;
						Debug.Log ("end elif");

Also the log only gets to “start foreach 2” then errors:

The variable Main_Cam of Spectate has not been assigned.

parents can be accessed through the objects transform.

in this case it would be