Republican presidential nominee Donald Trump hammered on foreign and domestic terror threats Thursday, laying the blame at the feet of President Obama and former Secretary of State Hillary Clinton, during an hour-long rally at Merrill Auditorium.

Trump focused most of his speech on the dangers of immigration – whether it was admitting refugees, asylum seekers or those who come here illegally. In Portland, he highlighted Somali refugees, linking them to crimes.

Portland and Lewiston have significant Somali populations.

“We have just seen many, many crimes, getting worse all the time, and as Maine knows, a major destination for Somali refugees. Right. Am I right?” Trump said. “They’re all talking about it. Maine. Somali refugees. You admit hundreds of thousands into Maine and into other places in the United States. Hundreds of thousands of refugees. And they’re coming from among the most dangerous territories and countries anywhere in the world. This is a practice that has to stop.”

Although he did not attend Trump’s rally, Mohamud Barre said it’s deeply disturbing that a man who wants to be the next president is suggesting that refugees are dangerous.

“It’s not fair to people who came here to live in this country peacefully,” he said.

Barre, who was interviewed by phone Thursday night, fled his homeland in Africa more than 20 years ago to settle in Portland. He serves as executive director of the Maine Access Immigrant Network, formerly known as Somali Culture and Development of Maine.

Mahmoud Hassan, president of the Somali Community Center of Maine, posted a statement on his Facebook page Thursday night.

“Somalis have been part of Maine since the early 1990s. We are citizens of this country and members of this community. We are participants in all sectors of this country and members of this community,” he said. “Trump’s rhetoric at his rally in Portland on Thursday was very destructive. It is damaging to the psyche of our youth to hear a major party presidential nominee condemn our culture and religion, especially while standing next to the governor of our state.”

Portland Mayor Ethan Strimling confirmed that members of the city’s Somali community are planning to hold a news conference at 2:30 p.m. Friday on the steps of City Hall.

Trump’s third visit to Maine – he came to Portland in March and Bangor in June – came amid a particularly tumultuous week for him, and one day after reports surfaced that Republican leaders were planning an intervention in hopes of getting Trump back on message.

National polls in the past two days show Clinton, the Democratic nominee for president, attracting more support, with her lead ranging from single digits to as high as 15 percentage points – 48 percent to 33 percent – in a McClatchy-Marist survey released Thursday evening. A Fox News poll taken after the conventions put Clinton up by 10 points, 49 percent to 39 percent.

RECITING DANGERS OF IMMIGRANTS

Known for veering off topic and into controversial areas, Trump largely stayed on point in Portland, steering clear of some of his more inflammatory statements. He didn’t mention his feud with the Muslim-American family of an Army captain who died in Iraq. Trump has drawn criticism from some Republicans and veterans for criticizing the soldier’s father for comments he made at the Democratic National Convention.

Over the course of nearly an hour, Trump focused on outside threats to the United States, whether it was through a broken immigration system or radical Islamic terrorism overseas. He vowed to rebuild the military and to close the border with Mexico by building a wall.

At one point, Trump listed a series of incidents involving legal immigrants, some of whom became U.S. citizens, who were caught plotting terror attacks here.

“People are pouring into our country, we have no idea who they are,” he said. “This could be the great Trojan Horse of our time.”

Trump referenced terror attacks in Nice, France, and San Bernardino, California. He said if regular citizens were armed, the death tolls would have been lower.

“If you had some guns on the other side of the equation that wouldn’t have happened, believe me,” he said, emphasizing his support of the 2nd Amendment.

Trump claimed that Obama, if he could do it over again, would never choose Clinton as his secretary of state, particularly because of the spread of the Islamic State and her use of a private email server, which Trump argued compromised U.S. national security.

“She’s a big problem,” he said to a capacity crowd of 1,600 people.

Trump’s message was applauded by his supporters interviewed after the rally.

Hillary Dearborn of Lynn, Massachusetts, attended with her father, Ron Dearborn, of Bradford, Maine. Both said Trump’s speech resonated with them.

“It sounded like all his speeches,” Ron Dearborn said. “And they all sound good.”

But Hillary Dearborn noted that Trump seemed “a little more low key” Thursday. Ron Dearborn said he thought Trump came off more mellow than usual because “he was in Maine, it just does that to you.”

Veterans Jason Riddle and Paul Fabula, of Milford, Connecticut, attended the rally together. Riddle was wearing a T-shirt that read “LGBT for Trump” in rainbow lettering. Riddle said that as an openly gay man, he realized he wasn’t a typical Trump supporter. When asked what he liked about Trump, Riddle said, “Everything, his foreign policy, getting rid of Obamacare, getting rid of Common Core (education standards), stop Hillary.”

LEPAGE CALLS HILLARY CLINTON CORRUPT

Gov. Paul LePage warmed up the crowd by criticizing the media for being too critical of Trump and giving Clinton a “free pass.”

“We need to reject corrupt politicians,” LePage said. “We need to make sure that we the people of this country defeat the queen of corruption.”

Trump repeated that “queen of corruption” line as soon as he took the stage, applauding the “very rambunctious and beautiful crowd.”

He largely ignored several outbursts by protesters, who were booed and shouted down by his supporters. Trump only mentioned the protesters once, saying, “It’s happening a little bit today, but it isn’t happening as much. I kind of miss my protesters.”

Trump criticized the Obama administration for a $400 million payment to Iran. He claimed the payment was to secure the release of four American hostages, saying, “that sets a terrible precedent. It’s sickening.”

Obama officials have disputed that claim, saying the payment was unrelated to the hostages and was a decades-old payment for weapons the U.S. had purchased.

Trump vowed to rebuild the military, saying he’d invest in more ships like those made at Bath Iron Works and build modern fighter jets. He said U.S. jets were so old that parts had to be salvaged from airplane “graveyards” and museums.

He also vowed to “knock the hell out of ISIS … and build a beautiful, beautiful, big, powerful wall, and Mexico is going to pay for it.”

Members of his own party have stepped up their criticism of Trump this week, especially after he hinted that he might not support some of their own candidates, including Sen. John McCain and House Speaker Paul Ryan, in their primary races. Trump has even complimented Ryan’s opponent.

Several national media outlets have reported that the Trump campaign is in disarray and that high-profile Republicans, including Republican National Committee Chairman Reince Priebus, are fed up with a candidate who they think can’t control himself. Some have even speculated that Trump may drop out of the race. But those aren’t the first allegations that Trump’s camp is in trouble, and so far he has weathered many gaffes and controversies.

Some media outlets have reported a fissure between Trump and his vice presidential running mate, Mike Pence. Trump has not endorsed Ryan in his primary, but Pence has. Trump told the Portland crowd that Pence’s endorsement came with his blessing. He then blasted the media, saying there is no break between him and Pence.

“The media, folks, they are so dishonest,” he said.

City officials estimated the crowd at 1,600, which effectively filled the venue given the space reserved for about 200 members of the media.

LePage was given a standing ovation when he introduced Trump.

“Thank you all for coming out for supporting the next president of the United States of America,” LePage said. He said the media has asked if he still supports Trump. “Yes. More than ever,” he said.

ADMIRATION FROM TRUMP SUPPORTERS

Some supporters began showing up as early as 7:30 a.m. to hear Trump, whose presidential campaign continues to attract grass-roots voter support even as he increasingly frustrates and alienates leaders of his own party.

Molly Ramirez and Jack Cianchette found themselves at the head of the line to get into the auditorium early in the day, just as they were back in March when Trump spoke at a rally in Portland.

During that rally at the Westin Harborview hotel, the two teenagers waited for hours in freezing temperatures and found themselves bonding over their mutual admiration of Trump. They now consider themselves best friends.

“I made a huge switch. I used to be a ‘Bernie Bro,’ ” said Ramirez, 19, of Bath. “At the end of the day, I realized I value Republican values over Democratic values. (Trump) is not graceful and he’s not eloquent, but he’s still my guy.”

Cianchette, an 18-year-old senior at Thornton Academy in Saco, attends rallies, volunteers to make phone calls and will be knocking on doors to speak to voters.

“If you’re going to show support for someone, you need to get involved,” he said.

Cianchette stood on the steps of City Hall as he chatted with Marge Trowbridge of Sanford, who was wearing a red “Make America Great Again” hat and Trump sweatshirt. It was her first Trump rally and she was clearly excited to hear him speak.

Trowbridge said she’s ready to have someone new lead the country – and she definitely doesn’t want it to be “Crooked Hillary” – but she doesn’t love everything that Trump says.

“If I had one thing to say to Donald Trump, I’d say, ‘You need to tone it down a bit,’ ” she said. “He needs to tone it down so people don’t get so angry and think he’s a negative person. I don’t think he’s a negative person.”

David Swyers, a Trump supporter from Maryland, likes the candidate because of his stance on immigration.

“I’m not a global person,” Swyers said. “I’m a USA person.”

Another Trump supporter in the crowd waiting outside City Hall was Philip Butler of Montana, who was visiting Maine for the first time. He hadn’t planned to see Trump speak while he was here, but the timing was right.

“I came to see Maine. The bonus was Trump,” Butler said. “You may not like his stance, but you have to respect that he’s brilliant. And he may not be popular all the time, but at least you know what you’re getting.”

Staff Writers Noel Gallagher and Gillian Graham contributed to this report.