From what can be deduced from the Qur'an, not all prophets brought a new law, or sharia, only five, Noah, Abraham, Moses, Jesus, and Muhammad, did.
Wuxuu dhahy Sheekhii: “Ubadkii madaxa ayey ruxeen, waxayna dhaheen: Waan ka bixin doonaa!! (oo laga fahmayo inay hadalka is dhaafinayaan).