Trying to make a renderer blink on and off, it's not working but I get no errors when building?

Here is my code:

	IEnumerator blinkTime () {
		if (blinking == true) {
			blinkTimeOn = true;
			while (blinkTimeOn == true) {
				renderer.enabled = false;
				yield return new WaitForSeconds (1f);
				blinkTimeOff = true;
				blinkTimeOn = false;
			}
			
			while (blinkTimeOff == true) {
				renderer.enabled = true;
				yield return new WaitForSeconds (1f);
				blinkTimeOn = true;
				blinkTimeOff = false;
			}
		}
	}

I’m trying to make an object’s renderer be enabled for a second then disabled for a second and this will repeat until blinking is set to false.

What exactly am I doing wrong here?

Edit: I should point out that I have “blinkTime” being called here:

void OnTriggerEnter(Collider otherObject) {

	if (otherObject.gameObject.CompareTag ("Enemy")) { 
		playerLives--;
		Timer = Time.time;
		blinking = true;
		blinkTime();

		if (playerLives < 1) {
			Destroy(this.gameObject);
		}
	}

The reason it isn’t working is because you’re not calling blinkTime via the StartCoroutine method.

enter code herevoid OnTriggerEnter(Collider otherObject) {
 
    if (otherObject.gameObject.CompareTag ("Enemy")) { 
       playerLives--;
       Timer = Time.time;
       blinking = true;
       blinkTime();
 
       if (playerLives < 1) {
         Destroy(this.gameObject);
       }
    }

Should be:

void OnTriggerEnter(Collider otherObject) {
 
    if (otherObject.gameObject.CompareTag ("Enemy")) { 
       playerLives--;
       Timer = Time.time;
       blinking = true;
       StartCoroutine(blinkTime());
 
       if (playerLives < 1) {
         Destroy(this.gameObject);
       }
    }