Barcelona needed extra-time to reach the Copa del Rey final on Wednesday, with a 3-2 aggregate win over Sevilla coming just two days after a police raid on the club and the arrest of their former president.
Having trailed 2-0 from the first leg, Danish international Martin Braithwaite hit the crucial goal in the fifth minute of extra-time with a diving header off a Jordi Alba cross.
Gerard Pique had equalised in the fourth minute of stoppage time with virtually the last play of the game to save Barca.
The veteran international headed in at the near post after a fine cross from Antoine Griezmann.
It was a much-needed win for Barcelona after former president Josep Maria Bartomeu, current chief executive Oscar Grau, head of legal services Roma Gomez Ponti and Bartomeu's advisor Jaume Masferrer were arrested by Catalan police, who searched the club's offices on Monday morning.
They were all questioned in relation to last year's "Barcagate" scandal.
The club holds its presidential elections later this week. The search of Barcelona's stadium was part of a probe into allegations the club carried out a defamation campaign against current and former players who were critical of Bartomeu.
That was after Ousmane Dembele, who scored in the 2-0 win at Sevilla in La Liga at the weekend, had given the 30-time Spanish Cup winners a 12th-minute lead in the second leg.
However, Sevilla could have killed the game off in the 73rd minute.
They were awarded a penalty when Lucas Ocampos was brought down by Oscar Mingueza.
However, Ocampos saw his tame right-foot effort from the spot saved by Marc-Andre ter Stegen.
Flagging Sevilla were then reduced to 10 men in injury time when Brazilian Fernando was red-carded for a foul on Francisco Trincao.
Spanish radio station Cadena Ser claimed in February 2020 that Barca covered up inflated payments to a company called I3 Ventures which it had hired to boost the image of the club on social media.
Part of the social media campaign included criticising current and former players like Lionel Messi and Xavi Hernandez, and iconic coach Pep Guardiola.
Barcelona will face either Athletic Bilbao or Levante, who are 1-1 in their semi-final, in the final on April 17 in Seville.
Before that, however, Barcelona will attempt another comeback effort when they take on Paris Saint-Germain in the second leg of their Champions League last 16 tie next week.
Barca trail 4-1 from the first leg
Madrid, Spain | AFP