Ref. No. 1209 Alif
In the name of Allah the most Gracious the most Merciful
The answer to your question is as follows:
Keeping beard to the extent of one fist in length is wajib in Shariah. If someone's beard is longer than a fist in size, he can trim it so as to make it a fist. However, trimming one's beard shorter than a fist is prohibited and sinful. Performing namaz behind an Imam who trims his beard is makrooh e Tahreemi. Such a person should not be chosen to lead any namaz. Nevertheless the prayers performed behind such an imam are valid and it is not required to repeat them. Practicing muslims should be preferred to be in the trustee or committee of masjid. Those who don’t keep proper beard for fear of Allah, how they can fear Allah in other matters!
However, if there is no person with proper beard available to lead the prayer, then it is better to offer the prayer in jamat (congregation) behind someone who trims his beard than to offer it alone.
And Allah knows best
Darul Ifta
Darul Uloom Waqf Deoband