Leonardo Silva Oliveira, a 26-year-old fugitive, had violated probation on charges of grand theft and burglary in Boca Raton, the South Florida Sun-Sentinel reported. But Leonardo Silva Oliveira, a 26-year-old cook, was the one arrested by the Coconut Creek Police Department on January 20.

Oliveira, the cook, told the Sun-Sentinel that he had no criminal history but had been put on “24-hour lockdown” before being allowed time out of his cell for an hour each day. In total, he spent five days in prison before authorities confirmed the mistake and released him.

In an email to Newsweek, Sergeant Scotty Leamon, the Coconut Creek Police Department’s public safety information officer, said the Palm Beach County Sheriff’s Office (PBSO) had contacted his department the day before Oliveira’s arrest saying they had a warrant for his arrest and an address in Coconut Creek.

“His name, driver’s license and social security number matched everything PBSO sent to us,” Leamon said. “One of our officers took a picture of him and sent it to a PBSO deputy, who verified that that was the man they were looking for.”

When Newsweek contacted the Palm Beach County Sheriff’s Office, Public Information Officer Teri Barbera said “PBSO does not have a role in this incident.”

According to the Sun-Sentinel, police ignored some differences between the men. For example, the fugitive Oliveira has tattoos on his arms—one of buildings and one of a clock—while the cook Oliveira has no tattoos. Their birthdays are also 10 days apart and, at the time of his 2017 arrest, the fugitive Oliveira weighed 213 pounds, while the cook Oliveira weighs less than 150.

At Oliveira’s first appearance in court, County Court Judge Phoebe Francois said she could not interfere with the case because it originated outside Palm Beach County and Oliveira had not hired an attorney in Broward County yet, the Sun-Sentinel reported.

He ended up hiring José O. Castañeda Jr., whom the Sun-Sentinel said filed a motion for Oliveira’s release and tracked down the other Oliveira’s father, who confirmed that his son was not the one in prison.

However, the hearing ended up not being necessary. Carey Codd, senior public information officer for the Broward County Sheriff’s Office, said in an email to Newsweek that the sheriff’s office requested the fingerprints when Oliveira said they had the wrong person, and “when it was determined that the fingerprints did not match, Oliveira was immediately released from jail.”

Castañeda told Newsweek that Oliveira is currently weighing his options to “figure out what the correct legal procedure would be next.” He called the fact that Oliveira was in prison for five days “horrendous.”

“No person should be in jail for any amount of time for something they didn’t do. It’s a worst fear, nightmare come true,” he said. “So there has to be some kind of procedure in place so this doesn’t happen again to anybody. Especially with modern technology, communications and resource availability, this shouldn’t be happening in the United States of America.”

According to the Sun-Sentinel, the other Oliveira has still not been found.

Update 01/27/22, 12:12 p.m. ET: This article was updated to add comment from attorney José O. Castañeda Jr.