Ahmad ibn Muhammad, from Al-Barqi, from Bukayr ibn A'yan, from one of the two Imams عليه السلام, said:
Imam عليه السلام said: “If an event requiring purification occurs in the mosque, there is no harm in performing wudu (ablution) in the mosque.”
Ali Akbar al-Ghaffari
Tahdhīb al-Aḥkām fī Sharḥ al-Muqniʿah, vol. 1, p. 379