2 Chronicles 19:1-6

1 King Jehoshaphat of Judah returned safely to his home in Jerusalem.
2 Jehu, son of the seer Hanani, asked King Jehoshaphat, "Why do you help wicked people and love those who hate the LORD? The LORD's anger is directed toward you because you have done this.
3 However, you've done some good things: You've burned the Asherah poles in this country, and you've wholeheartedly dedicated your life to serving God."
4 While Jehoshaphat was living in Jerusalem, he regularly went to the people between Beersheba and the mountains of Ephraim. He brought the people back to the LORD God of their ancestors.
5 He appointed judges in the country, in each fortified city of Judah.
6 He told the judges, "Pay attention to what you're doing. When you judge, you aren't doing it for a human but for the LORD. He will be with you when you hear a case.