Removed while loops

Commented out to fix build