During 1794, as the French fleet underwent repairs in Republican Toulon, the British Mediterranean fleet concerned itself with the invasion of Corsica, particularly the sieges of Bastia and Calvi. In March 1795 the French fleet again put to sea suffering a minor defeat at the Battle of Genoa and another in July at the Battle of Hyères Islands. These engagements marked the only encounters between the British fleet and the French fleet they so briefly held before the Royal Navy was forced to withdraw from the Mediterranean by the 1796 Treaty of San Ildefonso at which the Spanish changed sides, allying with France against Britain.