fix Integer[] and serializing into stream