An Iranian baby girl denied entry to the U.S. for lifesaving surgery under President Donald Trump’s travel ban has arrived in America for treatment.

Fatemeh Reshad was admitted at Oregon Health & Science University’s Doernbecher Children’s Hospital in Portland on Tuesday, doctors confirmed.

Her arrival ended a terrifying ordeal for the 4-month-old child’s family, after authorities had told them they’d have to wait 90 days to apply for a U.S. Visa.

Each passing day narrowed Fatemeh’s chance at survival because she has a heart defect called transposition of the great arteries, or TGA, doctors said.

family handout Tests on Fatemeh Reshad, a 4-month-old Iranian girl with a heart condition, confirm she has an injury to her lungs, doctors say.

“Fatemeh looks well. Our tests this morning have confirmed her diagnosis and the urgent need for treatment,” the hospital’s pediatric cardiologist Dr. Laurie Armsby said in a statement on Tuesday. “As we suspected, her heart condition has resulted in injury to her lungs, however, the studies today indicate that she has presented to us in time to reverse this process.”

A child in the U.S. with Fetemeh’s condition would typically receive treatment within the first week of life, making her needs of the utmost importance, Armsby, said at a press conference on Saturday.

"In the 90 years that Doernbecher has been a hospital, we've never turned away a child – and we never expect to." — Doernbecher Hospital (@OHSUDoernbecher) February 4, 2017

“The earlier the heart surgery is performed, the more likely the child will have a successful outcome. If the child does not undergo surgical treatment, there is no medical management that will prevent the outcome of death at a premature age,” the hospital said in a statement.

Fatemeh, whose grandparents and uncle live in Portland, was planning on meeting with the hospital’s doctors on Sunday. Then their plane was rerouted back to Iran at the last minute, doctors said.

After Trump’s Jan. 27 executive order banned refugees and citizens from seven predominantly Muslim countries from entering the United States, an attorney for the child’s family reached out to the U.S. State Department for help obtaining a waiver. They also contacted Sen. Jeff Merkley (D-Ore.), who alerted Secretary of State Rex Tillerson, CNN reported.

New York Gov. Andrew Cuomo (D) was also outspoken in his condemnation of Trump’s ban and its impact on the child, prompting the pediatric cardiac surgical team at New York’s Mount Sinai Hospital to offer to perform her surgery for free.

family handout Doctors say Fatemeh was long overdue for the surgery that's usually performed within the first week of a child's life.

The International Refugee Assistance Project arranged the family’s travel once it was given the go-ahead, and doctors at OHSU Doernbecher waived their fees.

“This was truly a team effort to beat the clock, given the medical and legal hurdles Fatemeh was facing,” Portland immigration attorney Jennifer Morrissey said in a statement that the hospital released.

Armsby said on Saturday that it would take a little time to prepare the baby for surgery and for her to recover after. She expressed hope that Fatemeh could return home to Iran in “a matter of months.”

A federal judge temporarily blocked Trump’s executive order on Friday. A ruling from a trio of federal appeals judges is expected later this week.

On Tuesday, the American Civil Liberties Union and the National Immigration Law Center filed a federal lawsuit against Trump’s ban on behalf of the IRAP and those impacted by his executive order.

“The President’s discriminatory executive order has trapped these vulnerable people in life-threatening conditions,” IRAP Director Becca Heller said in a statement. “We are currently devoting nearly all of our resources to finding emergency remedies to protect them, when we should be utilizing existing legal pathways that could offer them permanent safety.”