Corrected build list logic in contorller view