Added redundant generator removal.