Because he openly aligned France with Protestant powers, Richelieu was denounced by many as a traitor to the Roman Catholic Church. Military action, at first, was disastrous for the French, with many victories going to Spain and the Empire. Neither side, however, could obtain a decisive advantage, and the conflict lingered on after Richelieu's death. Richelieu was instrumental in redirecting the Thirty Years' War from the conflict of Protestantism versus Catholicism to that of nationalism versus Habsburg hegemony. In this conflict France effectively drained the already overstretched resources of the Habsburg empire and drove it inexorably towards bankruptcy. The defeat of Habsburg forces at the Battle of Lens in 1648, coupled with their failure to prevent a French invasion of Catalonia, effectively spelled the end for Habsburg domination of the continent, and for the personal career of Spanish prime minister Olivares. Indeed, in the subsequent years it would be France, under the leadership of Louis XIV, who would attempt to fill the vacuum left by the Habsburgs in the Spanish Netherlands and supplant Spain as the dominant European power.