Republican presidential candidate Donald Trump on Thursday criticized a North Carolina law that targets the LGBT community.

Appearing on NBC's The Today Show, Trump said that he's opposed to House Bill 2, which, among other things, prohibits transgender people from using the bathroom of their choice.

“North Carolina did something that was very strong. And they're paying a big price,” Trump said, a reference to an economic boycott against the state.

“You leave it the way it is. There have been very few complaints the way it is. People go, they use the bathroom that they feel is appropriate. There has been so little trouble,” he said.

“So, if Caitlyn Jenner were to walk in to Trump Tower and want to use the bathroom, you would be fine with her using any bathroom she chooses?” host Matt Lauer asked.

“That is correct,” Trump answered.

Trump's closest competitor, Texas Senator Ted Cruz, criticized Trump's comments, saying that he was too politically correct.

During a rally in Frederick, Maryland, Cruz referenced Trump's remarks, then rhetorically asked, “have we gone stark raving nuts?”

“Donald agreed with Hillary Clinton and Barack Obama in attacking the state of North Carolina for passing their bathroom ordinance,” Cruz said. “And Donald, on television this morning, said, gosh, he thought that men should be able to go into the girls’ bathroom if they want to. Now let me ask you, have we gone stark raving nuts? This is the political correctness.”

In defending the law, Cruz said that they were needed to protect women and girls from predators.

“Grown adult men, strangers, should not be alone in a bathroom with little girls. … That's basic common sense,” he said.

“I am waiting with anticipation for the new baseball caps, 'Make PC great again,'” Cruz added.

Within hours, the Cruz campaign was selling the hat on its website.