What country?
In the UK Vigilante justice is punished extremely hard.
If you commit a crime in the commission of preventing crime you will go to jail. There's a couple of things that are permitted and they're outlined as "detainment without excessive force" - for citizens arrest, and then it's only for the duration until a relevant authority can be called... with a maximum term of time that authority must be called.. It's extremely limited.
And one of the offences specifically not permissible for citizens arrest is inciting racial hatred.
https://www.westminstersecurity.co.uk/news/citizens-arrest-u...