Indonesian police said Sunday a 15-year-old girl who was raped by her older brother has been sentenced to six months in jail for having an abortion.

The brother received a two-year sentence for having sex with a minor.

The siblings were convicted Thursday at Muara Bulian District Court on the island of Sumatra.

Abortion is illegal in Indonesia, but is allowed in cases of rape. However, the abortion must be done by a healthcare professional within the first six weeks of the pregnancy.

The girl had the abortion six months into her pregnancy, officials say.

Authorities say it was revealed in court that her brother had raped her eight times since September.

Their mother is also facing charges because she helped to abort the fetus.

The siblings were arrested after a fetus was discovered at a palm oil plantation.

Prosecutors had asked for a one-year sentence for the girl and seven years for her brother. If was not immediately clear if prosecutors will mount an appeal.