The eminent Muslim scholar and renowned Da`iyah, Sheikh `Abdel Khaliq Hasan Ash-Shareef, states: “We heard about the hadith that the Prophet said Allah won’t accept the prayer of who drinks alcohol for 40 days, but as far as I know scholars of hadith criticized its authenticity and even if it is authentic, it does not mean that one who drinks alcohol or eats haram is not to offer prayer. Under all circumstances, one has to offer the obligatory prayers and to leave the matter of its acceptance to Allah.
In this regard, we’d like to state that there is a difference between performing an act of worship and its acceptance. Performing a prescribed act of worship as described in the Islamic Shari`ah is obligatory. But the acceptance of this act is something referred to Almighty Allah and this should not cause a hindrance to one from performing the prescribed prayer which is the second pillar of Islam. Rather, insisting to perform salah will be a cause of staying away from sins. May Allah guide us all to the right path!”