Enemies aren't respawning after they are all destroyed

I’ve just completed lecture 109, where we set up the methods to allow enemies to be created at the start, as well as after all the enemies have been destroyed. However, whilst the enemies spawn correctly at the beginning of the game, they do not respawn once they have all been destroyed.

void Start () {
        float distance = transform.position.z - Camera.main.transform.position.z;
        Vector3 LeftMost = Camera.main.ViewportToWorldPoint(new Vector3(0, 0, distance));
        Vector3 RightMost = Camera.main.ViewportToWorldPoint(new Vector3(1, 0, distance));
        MinX = LeftMost.x;
        MaxX = RightMost.x;

        //for every enemy position
        RespawnEnemies();
	}

void RespawnEnemies()
    {
        Debug.Log("Respawn Enemies");
        foreach (Transform child in transform)
        {
            Debug.Log("Spawning Enemy");
            GameObject Enemy = Instantiate(EnemyPrefab, child.transform.position, Quaternion.identity) as GameObject;
            //Puts the enemy at the location of the parent that holds the script.
            Enemy.transform.parent = child;
        }
    }

    bool AllMembersDead()
    {
        foreach (Transform childPositionGameObject in transform)
        {
            if (childPositionGameObject.childCount > 0)
            {
                return false;
            }
           
        }
        return true;
    }

    // Update is called once per frame
    void Update () {
        Vector3 CurrentPos = transform.position;
        if (moveRight)
        {
            transform.position += Vector3.right * moveDistance * Time.deltaTime;
        }
        else
        {
            transform.position += Vector3.left * moveDistance * Time.deltaTime;
        }
        float rightEdgeOfFormation = transform.position.x + (0.5f * width);
        float leftEdgeOfFormation = transform.position.x - (0.5f * width);
        if (leftEdgeOfFormation < MinX)
        {
            moveRight = true;
        }
        else if(rightEdgeOfFormation > MaxX)
        {
            moveRight = false;
        }
        if (AllMembersDead())
        {
            Debug.Log("Empty Formation");
            RespawnEnemies();
        }

    }

The issue seems to be that the Foreach loop in RespawnEnemies does not run when it is called from Update. “Respawn Enemies” is printed each frame but any Debug.Log placed within the ForEach loop is not printed.

Thanks in advance for any help.