In the end I decided to use np.where() instead
np.where()
simplified code:
mask = array1[:, 1] < array2[:, 1] array = np.where(mask, array1, array2)