Fix multiple array creations