Fix double AD stuff in arrays