(Photo by Sara D. Davis/Getty Images)

On Tuesday, President Barack Obama called out Republican presidential nominee Donald Trump and told him to stop “whining” about claims that the election is rigged against him.

“You start whining before the game’s even over?” Obama said during a news conference in the White House Rose Garden.

He said that Trumps claims that the system is “rigged” are “not based in facts” and added that there isĀ “no serious person out there who would suggest somehow that you could even rig America’s elections.”

He also warned about the danger of claims like his that, he said, could erode faith in democracy.

“One way of weakening America and making it less great is if you start betraying those basic American traditions that have been bipartisan and have helped to hold together this Democracy now for well over two centuries,” Obama said.

He went on to call the remarks unpresidential and further proof of Trump’s temperament precluding him from being president.

“It doesn’t really show the kind of leadership and toughness that you’d want out of a president. You start whining before the game’s even over? If whenever things are going badly for you and you lose you start blaming somebody else? Then you don’t have what it takes to be in this job.”