Their visa applications had been denied twice in two months.
After Afghanistan’s all-girls robotics team was denied entry to the United States twice in two months, President Donald Trump has reportedly intervened in the case so the six girls and their chaperon can enter the U.S. to attend a competition next week.
The denial of the girls’ visas had sparked outrage and puzzled onlookers since Afghanistan, a majority-Muslim nation, is not covered by Trump’s travel ban, which the Supreme Court allowed to go into limited effect last month. Teams from countries included in the ban, meanwhile, had gained access to the U.S. The Afghan girls’ repeated rejection was also seen as sending the wrong message to the people of Afghanistan, where U.S. troops are fighting Taliban militants who once barred girls from attending school, and undercutting the administration’s stated goal of empowering women abroad.
Subscribe to The World’s Most Powerful Women, Fortune’s daily must-read for global businesswomen.
“We could not be prouder of this delegation of young women who are also scientists — they represent the best of the Afghan people and embody the promise that their aspirations can be fulfilled,” said Dina Powell, Trump’s deputy national security adviser for strategy, in a statement after the reversal.
Politico reports that the president got wind of the case and asked National Security Council officials to see if anything could be done about it. The Department of Homeland Security eventually granted the girls entry to the U.S. on a system known as ‘parole,’ which will let them stay in the country for up to 10 days, though technically not a visa.
The non-profit that organizes the competition, which will see 163 teams from 157 countries compete this year, cheered the reversal.
“I truly believe our greatest power is the power to convene nations, to bring people together in the pursuit of a common goal and prove that our similarities greatly outweigh our differences,” First Global president Joe Sestak, a former U.S. Navy admiral and congressman, said in a statement. “That is why I am most grateful to the U.S. Government and its State Department for ensuring Afghanistan, as well as Gambia, would be able to join us for this international competition this year.”
Visa applications from Gambia’s team were also denied initially, but its members later gained admission.
The decision means the Afghan team will be able to watch their robot—which sorts balls by color—perform in person, rather than via video link. The girls’ presence at the competition will cap what’s been an arduous, dramatic journey from their war-torn nation, where young girls are still discouraged from engaging in academic study, especially in hard sciences like math.