Every one who wilfully disturbs or interrupts an assemblage of persons met for religious worship or for a moral, social or benevolent purpose is guilty of an offence punishable on summary conviction.
Arresting him after the service, which he was willing to do, is legal under that section.
Not quite, section 176(2):
Arresting him after the service, which he was willing to do, is legal under that section.