Hearing my concern, Rasulullah (sallallahu ‘alaihi wasallam) placed his blessed hand on my chest and made du‘aa in the following words:
اللهم ثبت لسانه واهد قلبه
“O Allah! Cause his tongue to be firm (in uttering the truth) and guide his heart (towards that which is right)!”
Thereafter, Rasulullah (sallallahu ‘alaihi wasallam) addressed me and said, “O ‘Ali! When the two disputing parties sit before you, then ensure that you do not issue any verdict or pass any judgment between them until you have heard the case of the second party, just as you heard the case of the first party. If you hold onto my advice, you will understand the situation correctly, and you will know how to decide among them.”
It is reported that on account of Rasulullah (sallallahu ‘alaihi wasallam) making this du‘aa for Hazrat ‘Ali (radhiyallahu ‘anhu) and giving him this advice, Hazrat ‘Ali (radhiyallahu ‘anhu) never faced difficulty when passing judgment.”
(Musnad Ahmed #882)