President Trump on Friday urged parents to vaccinate their children in the midst of a measles outbreak, offering the advice despite voicing repeated concerns in the past that child vaccinations can lead to autism a view rejected by government scientists.

“They have to get the shots. The vaccinations are so important. This is really going around now. They have to get their shots,” Trump told reporters at the White House as he prepared to travel to Indianapolis to address a gathering of the National Rifle Association.

The Centers for Disease Control and Prevention announced this week that measles cases have reached a record high in the United States this year since the disease was declared eliminated in 2000.

Though the CDC has said there is no link between vaccines and autism, Trump has voiced repeated suspicions over the past decade.

He weighed in on the issue on Twitter several times in 2012, writing at one point that “massive combined inoculations to small children is the cause for big increase in autism.”

“Many many people are thanking me for what I said about @autism & vaccinations. Something must be done immediately,” Trump tweeted later that year.

He also wrote: “Autism rates through the roof — why doesn’t the Obama administration do something about doctor-inflicted autism.”

Trump made similar arguments in 2014, tweeting: “Healthy young child goes to doctor, gets pumped with massive shot of many vaccines, doesn’t feel good and changes — AUTISM. Many such cases!”

At a Republican presidential debate hosted by CNN in 2015, Trump argued that vaccines needed to be given in smaller doses.

“Autism has become an epidemic,” he said. “I am totally in favor of vaccines. But I want smaller doses over a longer period of time.”