CAMBRIDGE -- A Cambridge mosque that was vandalized this summer is diverting donations it received to repair the damage to a local homeless shelter.

Baitul Kareem Mosque was vandalized in July, with its Kitchen trashed, signs destroyed and a TV stolen.

"To tell you the truth in the beginning it was a big shock for us, we really didn’t know what to make of it," said Nomaan Mubashir, president of the Baitul Kareem Mosque.

Police soon arrested a 35-year-old from Cambridge and charged him with a number of offences, including break and enter, possession of stolen property and damage over $5,000.

Investigators also quickly determined it was not a hate crime.

Mosque members soon found out the suspect was a drug addict who was also suffering from mental health issues and homelessness.

"We want to be part of the solution, we wanted to somehow make a difference," Mubashir said.

Leaders of the Mosque decided to divert donations it received to fix the vandalism elsewhere.

"We can raise our funds for the damage internally with the local Mosque community, but you know the homeless shelter needs the money more," Mubashir said.

Anne Tinker, the interim head of The Bridges said the funds are deeply appreciated.

"We were overwhelmed by that decision," she said. "(It) really sends a positive message to our community that people need support rather than being ostracized."

"Not only has a silver lining occurred, but good can come out of a bad situation," said Cambridge Mayor Kathryn McGarry.