This is an archived article and the information in the article may be outdated. Please look at the time stamp on the story to see when it was last updated.

Nissan Motor Co. executive Greg Kelly was released from detention in Japan on Tuesday after being granted bail over the alleged underreporting of his boss Carlos Ghosn’s pay.

The late-night release of Kelly, who is American, followed the Tokyo District Court’s approval earlier in the day of a bail request filed last week by his Japanese lawyer.

Kelly was freed on 70 million yen ($635,600) bail, ending his detention after more than a month.

Television footage captured the bespectacled Kelly, wearing a beige jacket, slowly walking out of the detention center and getting into a black car. The vehicle carrying Kelly, who was seated next to his lawyer and looking straight ahead, drove past reporters as cameras flashed. He was expected to go straight to a hospital for treatment of his chronic neck problem.

Kelly and Ghosn were detained in Tokyo immediately after their Nov. 19 arrest. They are charged with underreporting Ghosn’s pay by about 5 billion yen ($44 million) in 2011-2015.

Kelly’s Japanese lawyer sought bail after the court dismissed prosecutors’ request for more detention for the two to investigate their second allegation of underreporting Ghosn’s 4 billion yen ($36 million) pay.

Charges for alleged underreporting of 4 billion yen ($36 million) in the past three years are pending, and no trial date has been set.

Ghosn will be detained until Jan. 1 or longer since he also faces breach of trust allegations.

Prosecutors say Ghosn and Kelly are flight risks. Following his release, Kelly will have to follow rules set by the court, including those regarding his residence and travel, prosecutors have said.

Kelly, in a statement released Tuesday to the Japanese media through his Japanese lawyer, said he is innocent.

“I have not been involved in alleged false entry,” he said, according to a copy of the statement shown by Japanese networks and print media. “I believe my innocence will be revealed in the trial. I would like to have a judgment of non-guilty and restore my impaired reputation, and then return to my family as soon as possible.”

The arrests of Ghosn, who is an auto industry icon, and his right-hand man have triggered international attention and raised concerns about the Japanese practice of extended detentions.

Nissan has removed Kelly as representative director and Ghosn as chairman, but they are still company board members. The board of Renault SA, the French ally of Nissan, has retained him while naming an interim chair. Mitsubishi took a measure similar to Nissan.

Kelly, 62, joined Nissan North American in 1988 and worked in legal counsel and human resources at the company, and has been a member of the automaker’s board since 2012.

His American lawyer, Aubrey Harwell, has said he is innocent and that he only acted according to the law and according to company policy. Ghosn has also denied the allegations and told lawyers that he is determined to prove his innocence in court, according to Japanese media reports.

The scandal also raised concerns over the Japanese automaker and the future of its alliance with Renault, which in 1999 sent Ghosn to turn around Nissan, then on the verge of bankruptcy. He has since led Nissan’s rise to the world’s second-largest automaker.

Ghosn’s downfall is seen by some as a maneuver by others at Nissan to gain power in the alliance.

Kelly’s wife, Donna, had made a plea to the Japanese authorities for her husbands’ early release in a video message carried Tuesday by Japanese public broadcaster NHK and others. She said that her husband was “framed” by Nissan and that he also should be released to get his neck problem treated.

“Release Greg and allow him to come home and have the surgery he needs,” she said. “That is our family’s Christmas wish.”

Kelly reportedly suffers from spinal stenosis, a condition of a narrowing of the spaces in the spine that can cause pain, tingling or numbness.

He had been scheduled to undergo surgery in Nashville in early December, according to media reports.