PROVIDENCE, R.I. (WPRI) — A 28-year-old man is in custody after threatening a priest and several parishioners with a gun outside of a church in Providence Monday night, according to police.

The incident occurred around 8 p.m. outside of St. Mary’s Church at the corner of Barton Street and Broadway.

William Nesbitt was arrested at a nearby apartment, according to Maj. David Lapatin, and the gun used in the incident was recovered.

Nesbitt appeared in front of a judge Tuesday morning and was held on $20,000 with surety. The judge also ordered him to a pretrial services unit and to have no contact with the church.

“I’m not saying there’s anything wrong but we’d like to have you get an evaluation for substance abuse or mental health counseling whatever they recommend I want you to comply with their terms,” the judge said.

Nesbitt told the judge that St. Mary’s is not his parish. He is also a bail violator, therefore the judge held him without bail with his next court date on Nov. 9.

St. Mary’s is the same church where a priest, Father James Jackson, was arrested over the weekend for possession of child pornography.

The 66-year-old is facing several charges, including possession of child pornography after state police say the internet connection at the church was linked to the sharing of child porn.

Jackson was arraigned by a justice of the peace and was held on $5,000 surety bail.

He was brought to the ACI and is expected to appear in court on Nov. 15.