(BOONE CO.) - A central Indiana music teacher accused of child molestation will end up spending only two days in jail.

John Olivera was sentenced to two years Wednesday after a judge accepted a plea deal in the case. Of the sentence, one year and 363 days of jail time were suspended (Olivera was given credit for two days served). He'll serve the two year sentence on probation.

The plea deal had the support of Olivera's accuser and her mother, who both asked the court to accept the agreement. The girl, who sat beside an advocate in court to read her statement, told the court that Olivera destroyed her life and said the ordeal tore apart her family.

Olivera didn't make a statement in front of the court Wednesday. He was ordered to have no contact with the girl and can't hold jobs that involve regular contact with children.

Olivera was originally charged with three counts of child molestation. In February, he pleaded guilty to a lesser charge of battery on a person less than 14 years old.

In August 2015, allegations surfaced that Olivera molested a former student. According to court documents, a 12-year-old girl woke up one night to find Olivera touching and fondling her. The incident happened in the summer of 2014. The girl told investigators that Olivera acted like nothing happened the next day. A similar incident happened months later.

The girl's mother found text messages between her daughter and a juvenile male describing what happened, according to court documents.

Olivera worked as lead instructor and band director at Michele Studio in Fishers. He was also a worship leader at the Life Center in Southport and managing director of Urban Youth Ministry in Indianapolis, according to an online profile. He has denied the molestation allegations.

Olivera has denied the molestation allegations. His attorney said they agreed to plead guilty to battery so that the case could be resolved.