Extracted the fill preparation pahse to method. Reducing loop
complexity.