Perhaps, this is the biggest problem in multi-antenna array design.
When start design a multi-antenna array, the first step solving/avoiding this issue is to chose the proper feed network for a particular array design. After the feed network type was chosen and designed, not much can be done from this side, to eliminate its influence on the array radiated pattern.
Other two factors, which combined to the feed network charatcteristic, and may affect the radiated pattern, are: the mutual coupling between antenna elements, and also the impedance change sensitivity of each element to its place into the array. Those two charateristics may be minimized by careful single-antenna element proper design.
Unfortunately, there is not a simple solution for this issue...