Got rid of allocating data in array