Court documents say the man did not necessarily play a part in the terror cell
A second suspect arrested in the aftermath of last week's twin terror attacks in Spain has been freed.
Under the terms of his release, Salh el Karib's passport has been confiscated and he will be required to attend court once a week.
El Karib runs an internet cafe in the town where most alleged members of the 12-strong terror cell lived, and he was accused of purchasing plane tickets for two men in the group.
Court documents suggest credit cards in his name were used to buy flights for Driss Oukabir as well as Abdelbaki es Satty, the imam believed to have masterminded the plot.
The investigation has found that el Karib's business sells plane tickets as part of its services, meaning he did not necessarily play a part in the terror cell.
"There is no indication that the detainee had any relationship with the people allegedly involved in the terrorist organisation that is being investigated," the document said.
El Karib was among four surviving suspects who appeared in Madrid's National Court after a terror attack on Barcelona's Las Ramblas boulevard and another attack in nearby Cambrils left 15 people dead.
At Tuesday's hearing, Mohamed Aalla was freed after a judge ruled that the evidence against him was "not solid enough."
Police were also granted 72 more hours to hold el Karib in custody while further investigations took place.
The other two suspects - Driss Oukabir and Mohamed Houli Chemlal - were charged with murder, membership of a terror organisation and the possession of explosives.
In court, Chemlal had revealed that the cell was planning to strike some of Barcelona's best-known monuments - including the famous Sagrada Família basilica.
Spanish authorities are continuing to investigate the attacks, which also injured 120 people.
Seven people remain in a critical condition, and five others have serious injuries.
The terror attacks had been preceded by an explosion at a house in Alcanar, a town that lies south of Barcelona.
It later emerged that the property was linked to the attacks and had been used as a makeshift bomb factory - and es Satty had died in the blast.