The Messenger of Allah ﷺ forbade to take retaliation in the mosque, to recite verses in it and to inflict the prescribed punishments in it. (Using translation from Abū Dāʾūd 4490)
نَهَى رَسُولُ اللهِ ﷺ أَنْ يُسْتَقَادَ فِي الْمَسْجِدِ أَوْ يُنْشَدَ فِيهِ أَوْ تُقَامَ فِيهِ الْحُدُودُ