Full Sharh — Mishkat al-Masabih 3548
وَعَنْ أَبِي سَعِيدٍ قَالَ: قَالَ رَسُولُ اللَّهِ صَلَّى اللَّهُ عَلَيْهِ وَسَلَّمَ: «إِنَّ أَحَبَّ النَّاسِ إِلَى اللَّهِ يَوْمَ الْقِيَامَةِ وَأَقْرَبَهُمْ مِنْهُ مَجْلِسًا إِمَامٌ عَادِلٌ وَإِنَّ أَبْغَضَ النَّاسِ إِلَى اللَّهِ يَوْمَ الْقِيَامَةِ وَأَشَدَّهُمْ عَذَابًا» وَفِي رِوَايَةٍ: «وَأَبْعَدَهُمْ مِنْهُ مَجْلِسًا إِمَامٌ جَائِرٌ» . رَوَاهُ التِّرْمِذِيُّ وَقَالَ: هَذَا حَدِيثٌ حَسَنٌ غَرِيبٌ
English Translation
Abu Sa'id reported God’s Messenger as saying, “The one who will be dearest to God and nearest to Him in station of the day of resurrection will be a just imam, and the one who will be most hateful to God on the day of resurrection and will receive the severest punishment (or as a version has, will be farthest from Him in station) will be a tyrannical imam.” Tirmidhi transmitted it, saying this is a hasan gharib tradition.
Source
Mishkat al-Masabih(مشكاة المصابيح)
The Offices of Commander and Qadi
Hadith Number
3548