Luther said many things in many different situations. He even said “unLutheran” things, such as good works are evidence of true faith. If you can find quotes in Luther’s Works that support works-righteousness, does that mean Luther had no coherent stance?
To the contrary, when looking at the total Luther, it’s evident that his theology (the cross alone; the bondage of the will, the freedom of the Christian, and the like) has a dynamic that is consistent from the young Luther to the older Luther in spite of what he may have said in a particular sermon on a particular occasion.