"In the days of his flesh, Jesus offered up prayers and supplications, with loud cries and tears, to him who was able to save him from death, and he was heard because of his reverence."
Did you read that? Jesus was heard BECAUSE of his reverence. He was not simply heard because He was ontologically righteous as the Second Person of the Trinity. But he was heard because he obeyed as a flesh and blood human being. So what? you say. Well, this demonstrates that Jesus obedience as a human being, his life, not just his death was critical in our redemption. His obedience to God's law in his life was part of the righteousness that was imputed to us that we might be right before God.
That is why Paul declares to the Corinthians, "God made him who had no sin to be sin for us, so that in him we might become the righteousness of God." The "no sin" aspect speaks of a necessary aspect of Christ's redemptive work. His atonement for sin requires a sinless sacrifice, one which obeyed God in every way. Paul also says "For as by the one man's disobedience [Adam] the many were made sinners, so by the one man's obedience [Jesus} the many will be made righteous." He did not merely mean to say that Jesus was obedient in offering Himself up to death (although it includes that), he also means the obedience of His whole life. Otherwise Jesus could have merely been killed by Herod as a small baby and that would have been sufficient for us. His death is not all that mattered. Jesus declared there were things he needed to do in his life "to fulfill all righteousness" (Matthew 3:15)