Spain’s Supreme Court on Friday overruled two lower courts and sentenced five men to 15 years in prison each for raping an 18-year-old woman.

The case had triggered an outcry because the lower courts last year convicted the men of the lesser crime of sexual abuse, handing down nine-year sentences.

The public prosecutor, the victim and regional authorities appealed to the Supreme Court, asking for a rape conviction and longer sentences. The men’s lawyers wanted them acquitted, arguing that the woman consented.

Women’s rights advocates had expressed anger about what they saw as the lower court’s leniency and the confirmation of that sentence by a second court. They have organized national protests since the 2017 verdict.

The judges heard both sides’ arguments Friday and gave their verdict after just two hours.

They said that in accordance with legal precedent, the attack could be classified as rape, which was aggravated by being performed in a group.

The victim didn’t consent to the acts, the judges said, and was subjected to 10 acts of sexual aggression in “a genuinely intimidating scene.”

They found that the men also made videos of their attack.

Prosecutors said the men boasted about the 2016 attack during Pamplona’s San Fermin festival on a WhatsApp group named “La Manada,” or “The Pack.”

The case brought widespread criticism from women’s groups after the first court agreed to study a defence detective’s report on the woman’s behaviour after the incident, which some said made it appear that it was the victim who was on trial.