SEOUL, South Korea — A Korean-American woman accused of praising rival North Korea in a recent lecture was deported from South Korea on Saturday, in the latest in a series of cases that critics say infringe on the country’s freedom of speech.

The Korea Immigration Service decided to deport Shin Eun-mi, a California resident, after prosecutors determined that her comments violated South Korea’s National Security Law, agency official Kim Du-yeol said.

Shin departed the country on a flight to the U.S. on Saturday evening, an immigration official said on condition of anonymity, citing department rules.

Shin said she hopes to be able to return to both Koreas.

In South Korea, praising North Korea can be punished by up to seven years in prison under the National Security Law.

In Washington, State Department spokeswoman Jen Psaki said Shin had been barred from exiting South Korea for three weeks, and the U.S. has seen reports indicating the prosecution has asked for her to be deported and banned from the country for five years. Shin posted stories about her trips to North Korea on OhmyNews, a popular South Korean online news site. Her book on her trips was included in a government-designated reading list in 2013, but the Culture Ministry removed it this week. Ministry officials said they will seek to retrieve 1,200 copies that were distributed to libraries across South Korea.

During a November lecture in Seoul, Shin said many North Korean defectors living in South Korea had told her they want to go back home and that North Koreans hope new leader Kim Jong Un will bring change. She also praised the taste of North Korean beer and the cleanliness of North Korea’s rivers.

Shin has said she had no intention of praising the country and was only expressing what she felt during her travels there.

Conservatives have sided with government moves to expel Shin, accusing her of ignoring North Korea’s abysmal human rights conditions. But her impending deportation drew sharp criticism from liberals who say the conservative government of President Park Geun-hye is clamping down on freedom of speech.