(Bamidbar 28:1-2) "And the L-rd spoke to Moses, saying: Command the children of Israel … My offering, My bread, etc." What is the intent of this? Because Moses said (Ibid. 27:16-17) "Let the L-rd appoint" (over Israel) "someone who will go out before them, etc." An analogy: A king had a wife who, before her death, charged him over her sons saying: I pray you, take care of my sons, etc. The king: Before you charge me over my sons, charge them over me, that they not rebel against me and not cheapen me.

Thus the Holy One Blessed be He to Moses: Before you charge Me over My sons, charge them over Me, that they not cheapen Me and that they not exchange My honor for foreign gods. And thus is it written (Devarim 31:19-20) "And now, write for yourselves this song … When I bring them to the land … and they turn to other gods and spurn Me, etc."