War of the Castilian Succession
As captain-general Albergaria was also responsible for the island's defense. However, in 1480 a Castilian corsair attacked Vila do Porto during the War of the Castilian Succession, sacking the town. Albergaria was captured and taken prisoner to Castile, where he was ransomed. He paid his own ransom eight days before peace were declared by Afonso V and Ferdinand of Castile at the end of 1480.