It’s important to read the Scriptures in context. Jesus’ point in the Matthew passage (chapters 5-7) is “YOU CANNOT KEEP THE LAW PERFECTLY, AND ONLY PERFECTION IS ACCEPTABLE TO GOD” (verse 48) – ergo, you need grace!! That’s why He uses such major hyperbole - if you call your brother a fool you’ll burn in hell just as surely as if you murdered him, if you look at a woman and think she’s sexy you’re going to hell just as surely as if you’d seduced her. Pluck out your eye and throw it away if noticing pretty girls is a temptation to you. . . . but then he says “Do unto others as you would have them do unto you; this is the Law and the Prophets.” And “Not everyone who calls me “Lord” shall enter the Kingdom of Heaven, but the one who does the will of my Father who is in Heaven.”
But now I’m off topic. The question of the keeping of the Jewish Law was addressed by the Council at Jerusalem, which is described in Acts 15. The inquiry came from the mission to the Gentiles, regarding whether or not those who became Christians were obligated to keep the Jewish law. The apostles and elders met to discuss the issue and rendered a decision that is recorded in Acts 15:28-29, binding the Gentile Christians only on the prohibition of idolatry (via eating food sacrificed to idols, which would be participating in the rite), consuming blood, and unchastity. Similarly the Church transferred the Sabbath obligation to be on the day of the Eucharistic celebration rather than on the Jewish Sabbath (probably after the decree banishing Christians from the synagogues, when the Scripture-teaching-and-prayer of the synagogue worship was appended (pre-pended?) to the Eucharistic worship).
The Ten Commandments are not abrogated by Jesus. The Old Covenant is not set aside, it is fulfilled in the New. Jesus’ sacrifice was prefigured by the Temple sacrifices, now they are not needed. The rituals of clean-and-unclean were types or symbols of the state of grace we enter through Him. Etc. . . So the apostles and their successors, including Paul, were not undermining Jesus’ authority but exercising the authority and responsibility He gave them. (See John 16 and 20).
hope that helps?