A man has received 20 lashes after an Islamic court sitting in Bauchi convicted him of homosexual offences.
Under Islamic law, courts can punish homosexual acts by stoning to death.
But the judge said he took into account that the Muslim man, Mubarak Ibrahim, 20, carried out the acts seven years ago, and had stopped the practice.
Earlier this month, President Goodluck Jonathan signed into law a bill which bans same-sex marriages, gay groups and shows of same-sex public affection.
According to BBC, along with Mr. Ibrahim, 11 other Muslims and a Christian man were arrested last month accused by the authorities of being homosexuals. He was also ordered to pay a fine of about $30 (£18).
Mr. Ibrahim said he was relieved that Judge Nuhu Muhammad had been lenient on him and had not sentenced him to death.
He was lashed with a whip, made of animal skin smeared with oil.
Mr. Ibrahim, who had pleaded guilty to the charge, was ordered to lie on a bench, and an official whipped his back in front of a packed courtroom. He screamed in pain while being lashed.
The trial of two other men was adjourned to 23 January.
The fate of the nine other men arrested on the same charge is unclear but on Wednesday the Sharia Commission in Bauchi said the Christian would be tried by a “conventional court”, not an Islamic court.
Nigeria’s first online