explicitly indexed arrays were causeing problems

thanks @donatj