وَعَنْ أَنَسِ بْنِ مَالِكٍ رَضِيَ اللَّهُ عَنْهُ قَالَ بَايَعْنَا رَسُولَ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَآلِهِ وَسَلَّمَ عَلَى السَّمْعِ وَالطَّاعَةِ فَقَالَ ”فِيمَا اسْتَطَعْتُمْ“
It is narrated from Sayyiduna Anas bin Malik, may Allah be pleased with him, he says: We pledged allegiance to the Messenger of Allah, peace and blessings be upon him, that we would listen to the ruler and obey him. The Messenger of Allah, peace and blessings be upon him, said: But according to your ability.