A German-Turkish writer and a critic of President Recep Erdogan has been freed after he was detained in Spain at the request of the Turkish government.
Dogan Akhanli was arrested over the weekend as he holidayed in the city of Granada, in southern Spain.
He was conditionally released after a court hearing but was ordered to remain in Madrid while Turkey's extradition request was considered.
Mr Akhanli has previously written about the mass killings of Armenians in Turkey in 2015, a sensitive subject for the Turkish authorities who reject the widely accepted view that this constituted a genocide.
He has also written extensively about human rights in Turkey.
On his website, Mr Akhanli says he was held as a "political prisoner" in Turkey in the 1980s, when he claims he was tortured at an Istanbul prison.
He fled to Germany where he was granted political refugee status and became a citizen in 2001. He has since spent most of his time in the country.
German Foreign Minister Sigmar Gabriel intervened on his behalf and requested that he was not extradited from Spain.
German Chancellor Angela Merkel also criticised the arrest, which has been widely seen as being politically motivated, saying Turkey had abused Interpol, the international police agency.
"It is not right and I'm very glad that Spain has now released him. We must not misuse international organisations like Interpol for such purposes," she said.
Mr Akhanli's arrest was happened following an Interpol "red notice" which is a request made by national police forces to arrest an individual for extradition. This does not mean the person is wanted by Interpol itself.
Relationships between Turkey and the EU have been under growing strain since last year's failed military coup in Turkey.
European-Turkish nationals are among some 50,000 people detained since the failed coup in a crackdown by President Erdogan.
Ms Merkel said the case was one of many, adding "we have massively changed our Turkish policy recently... because it's quite unacceptable Erdogan does this".
European countries with large Turkish diasporas such as Germany and Austria have grown increasingly concerned about what they see as Ankara's attempts to use Turkish populations to influence domestic policies.
On Saturday, President Erdogan urged Turks in Germany to "teach a lesson" to the country's "anti-Turkish" mainstream parties in next month's election.
Additional reporting by agencies.