UI button not working

I am very close to having this working but can longer figure out what isn’t working what is happening is when I click a button it is not calling the function I have hooked up to it. here is the code a lot more than needed but don’t want to miss something that may help the game over function is being called from another script and is working the button turns off and on but when clicked does not trigger the restart function.

	public GameObject hazard;
	public Vector3 spawnValues;
	public int hazardCount;
	public float spawnWait;
	public float startWait;
	public float waveWait;

	private int score;
	private bool gameOver;
	private bool restart;
	private GameObject gameOverText;
	private GameObject restartButton;

	// Use this for initialization
	void Start () {	
		gameOverText = GameObject.Find("Canvas/GameOverText");
		gameOverText.SetActive (false);
		restartButton = GameObject.Find("Canvas/Restart");
		restartButton.SetActive (false);
		StartCoroutine (SpawnWaves ());
	}
	
	// Update is called once per frame
	void Update () {
	
	}

	IEnumerator SpawnWaves(){
		yield return new WaitForSeconds(startWait);

		while(true){
			for(int i = 0 ; i <= hazardCount; i++){
				Vector3 spawnPosition = new Vector3 (Random.Range(-spawnValues.x,spawnValues.x), spawnValues.y, spawnValues.z);
				Quaternion spawnRotation = Quaternion.identity;
				Instantiate (hazard, spawnPosition, spawnRotation);
				yield return new WaitForSeconds(spawnWait);
			}
			yield return new WaitForSeconds(waveWait);

			if(gameOver){
				restartButton.SetActive (true);
				restart = true;
				break;
			}
		}
	}

	public void GameOver(){
		gameOver = true;
		gameOverText.SetActive (true);
	}

	public void Restart(){
		Debug.Log ("restarting");
		if (restart) {
			Application.LoadLevel (Application.loadedLevel);
		}
	}

}

here is the code that calls gameover function

	public GameObject explosion;
	public GameObject playerExplosion;
	public int scoreValue;

	private GameController gameController;

	void Start(){
		GameObject gameControllerObject = GameObject.FindWithTag ("GameController");
		if (gameControllerObject != null) {
			gameController = gameControllerObject.GetComponent<GameController> ();
		} else {
			Debug.LogWarning("Controller was not found");
		}
	}

	void OnTriggerEnter(Collider other){
		if (other.tag == "Boundary") {
			return;
		}
		Instantiate (explosion, transform.position, transform.rotation);
		if(other.tag == "Player"){
			Instantiate (playerExplosion, other.transform.position, other.transform.rotation);
			gameController.GameOver();
		}

		Scoring.score += scoreValue;
		Destroy (other.gameObject);
		Destroy (gameObject);
	}

Did you ever figure this out? I was having so much trouble with getting a button to work, but the solution ended up being that I was missing the EventSystem piece of the UI.

Check that your scene has an EventSystem object, and add one if not from GameObject -> UI -> EventSystem.