Two Democrats seeking the party's 2020 presidential nomination faced sharp criticism on social media Saturday after linking the massacre in El Paso, Texas, to President Trump's rhetoric.

Sen. Amy Klobuchar, D-Minn., one of nearly two-dozen Democrats hoping to block Trump's bid for a second term in the White House, made her remarks at a labor forum event in Las Vegas.

“The individuals who do the shootings are responsible," Klobuchar said, referring to mass shootings such as the one in El Paso that left 20 dead and 26 injured, "but I do think Trump's rhetoric has fueled more hate in this country.”

EL PASO SHOOTING LEAVES 20 DEAD, 26 INJURED; INVESTIGATORS PROBING POTENTIAL 'NEXUS TO HATE CRIME'

Klobuchar also pushed for gun reform legislation on Twitter.

"Today innocent people—families—went to that mall in El Paso," she wrote. "Some of them never came home. The U.S. House has passed common sense gun safety legislation. It is long past time to pass it in the Senate. The question to ask: Whose side are you on? The NRA’s or the people’s."

Former U.S. Rep. Beto O'Rourke also placed some blame on the president for the shooting while speaking in El Paso, which he represented when he was in Congress.

"He is a racist, and he stokes racism in this country," O'Rourke told reporters. "We've had a rise in hate crimes every single one of the last three years. During an administration where you've had the president call Mexicans rapists and criminals."

The shooting in El Paso occurred at a Walmart store on Saturday afternoon. A suspect was later taken into custody, police said.

While some on social media praised the candidates' comments, others criticized them for politicizing the shooting.

“Amy! Thank you for all that you do and we need more! This president needs to be held accountable for these deaths and this carnage. He is complicit, he is an accessory to this crime as he instigates hate amongst his followers,” one supporter wrote.

"Beto O'Rourke is completely correct," another added.

Another user wrote that it’s Democrats and Congress who are to blame for not acting on gun control.

TRUMP, 2020 DEMS CONDEMN EL PASO MASS SHOOTING: 'ACT OF COWARDICE'

“I see you blamed President Trump as usual for supposed hate crime in shootings in El Paso GMAFB you Democrats always trying to get a Political over this BS. You have had years to fix the gun violence but you and all of congress can’t work,” they wrote.

One user said that Klobuchar is the one spouting hateful rhetoric.

“Ms klobuchar enough, don’t blame President Trump your hateful rhetoric fuels hate so just because your running for President,” the Twitter user wrote.

"@BetoORourke Could you stop the politics long enough to be respectful to all that have been affected by this horrendous act of violence," another criticized.

During last week's Democratic presidential debate in Detroit, Klobuchar said she supports an assault weapons ban as well as universal background checks for gun buyers. She also criticized the president, saying he hadn't done enough in response to a shooting in Parkland, Fla., that left 17 people dead in 2018.

Several of the other Democratic presidential candidates posted similar messages Saturday pushing for gun safety legislation in Congress.

CLICK HERE TO GET THE FOX NEWS APP

The president reacted to the shooting on Twitter, writing, “Today’s shooting in El Paso, Texas, was not only tragic, it was an act of cowardice. I know that I stand with everyone in this Country to condemn today’s hateful act. There are no reasons or excuses that will ever justify killing innocent people....”