STOCKHOLM (Reuters) - China expelled a Swedish national taken into custody this month on suspicion of acts detrimental to the country’s national security, China’s Foreign Ministry said on Tuesday.

China has drawn international condemnation over a crackdown on rights lawyers. Three weeks ago, it detained Peter Dahlin, a 35-year-old co-founder of the Chinese Urgent Action Working Group that worked with Chinese human rights lawyers.

Michael Caster, a spokesman for the group said in a statement that Dahlin’s girlfriend, Pan Jinling, who had been detained around the same time, had also been released.

The Swedish foreign ministry, which had earlier announced Dahlin’s release, said it remained concerned about naturalized Swedish citizen Gui Minhai, a Hong Kong-based bookseller who had vanished in October in Thailand.

Dahlin was not released, but deported, said Hua Chunying, a spokeswoman for China’s Foreign Ministry.

“Dahlin confessed during the process of questioning to suspected crimes,” Hua told reporters, adding that China expelled him according to the law and had provided appropriate access for Swedish consular officials during his detention.

Dahlin’s supporters have said his confession, broadcast by state-run China Central Television (CCTV), appeared to have been made under duress.

Western governments and rights groups have criticized China for its use of televised confessions in recent weeks, saying they violate due process and the rights of the accused.

Gui appeared on Chinese state television this month, saying he had surrendered to authorities over a fatal drink-driving offence more than a decade ago.

The disappearance of Gui and other booksellers has prompted fears that mainland Chinese authorities may be using shadowy tactics that erode the “one country, two systems” formula under which Hong Kong has been governed since its return to China from British rule in 1997.

Sweden’s Foreign Minister Margot Wallstrom said she welcomed Dahlin’s release, but expressed concern over Gui.

“Meanwhile, I am greatly concerned over the detained Swedish citizen Gui Minhai,” Wallstrom said in a statement, adding that Sweden was working to get clarity on his situation and an opportunity to visit him.