What happens if different factions within the congregation each appoint their own Imam after the original Imam breaks purity?
Chapter on Praying with Impurity and Other Matters
Al-Mughni
Book of Prayer
Primary text
If each group within the followers appoints their own Imam and prays behind them, the analogy of the madhhab (school) and the position of al-Shafi'i suggest this is permissible. This is because the followers have the right to pray individually, which analogously allows them to appoint a leader, just as they could at the start of prayer. It is also valid if some pray behind an appointed leader while others pray individually.
Supporting text
The Ashab al-Ra'y (Hanafi school) maintain that the prayers of all parties are invalidated in this scenario.