17 Jehoiada then made a covenant between the Lord and the king and people that they would be the Lord's people. He also made a covenant between the king and the people. 18 All the people of the land went to the temple of Baal and tore it down. They smashed the altars and idols to pieces and killed Mattan the priest of Baal in front of the altars. Then Jehoiada the priest posted guards at the temple of the Lord. 19 He took with him the commanders of hundreds, the Carites, the guards and all the people of the land, and together they brought the king down from the temple of the Lord and went into the palace, entering by way of the gate of the guards. The king then took his place on the royal throne. 20 All the people of the land rejoiced, and the city was calm, because Athaliah had been slain with the sword at the palace. 21 Joash[1] was seven years old when he began to reign.[2]

Matthew Henry's Commentary on 2 Kings 11:17-21

Commentary on 2 Kings 11:17-21

(Read 2 Kings 11:17-21)

King and people would cleave most firmly to each other, when both had joined themselves to the Lord. It is well with a people, when all the changes that pass over them help to revive, strengthen, and advance the interests of religion among them. Covenants are of use, both to remind us of, and bind us to, the duties already binding on us. They immediately abolished idolatry; and, pursuant to the covenant with one another, they expressed mutual readiness to help each other. The people rejoiced, and Jerusalem was quiet. The way for people to be joyful and at peace, is to engage fully in the service of God; for the voice of joy and thanksgiving is in the dwellings of the righteous, but there is no peace for the wicked.