NET
31 When the chariot commanders saw Jehoshaphat, they said, “He must be the king of Israel!” So they turned and attacked him, but Jehoshaphat cried out. The Lord helped him; God lured them away from him.
Darby
31 And it came to pass when the captains of the chariots saw Jehoshaphat, that they said, That is the king of Israel; and they surrounded him to fight; and Jehoshaphat cried out, and Jehovah helped him; and God diverted them from him.
KJV
31 And it came to pass, when the captains of the chariots saw Jehoshaphat, that they said, It [is] the king of Israel. Therefore they compassed about him to fight: but Jehoshaphat cried out, and the LORD helped him; and God moved them [to depart] from him.