For all the Prophets and the Law prophesied until John, and if you are willing to accept it, he is Elijah who is to come.
Matthew 11:13-14

The Law and the Prophets were focused on the moment of John's ministry. Not that their message ended with him, but that they all looked forward to the message he had to deliver concerning the Messiah. John came in the role and office of Elijah, calling the people to repentance and announcing the arrival of the Kingdom, as prophesied in Malachi 3-4 and by all of the preceding prophets.