Aryna Sabalenka is glad she changed her mind about playing at the Madrid Open.

Two weeks after nearly withdrawing from the tournament because of a muscle injury, Sabalenka was standing on center court with the winner’s trophy in her hands on Saturday.

Sabalenka defeated top-ranked Ash Barty 6-0, 3-6, 6-4 for her 10th WTA title — and first on clay.

Sabalenka’s victory, coming two weeks after she was hurt in a loss to Barty in the Stuttgart final, will move the Belarus player to No. 4 in the world next week.

“To be honest, after the final in Stuttgart I was injured, I couldn’t even move, I really wanted to withdraw from here,” she said. “And I don’t know how, but my team … the recovery was really good. In four days they made me feel much better. Somehow I’m here standing as the champion of this tournament.”

Sabalenka injured an adductor muscle in the three-set loss in Germany to Barty, who had won all of her three previous finals this year.

It was the second title for Sabalenka this year after winning the season-opener in Abu Dhabi. She also lost to Barty in the Miami quarterfinals.

In the men’s semifinals, Zverev followed his triumph over Rafael Nadal with a win over Dominic Thiem to reach another Madrid Open final. He will face No. 10-ranked Berrettini, who beat Casper Ruud 6-4, 6-4.

No. 6 Zverev defeated No. 4 Thiem 6-3, 6-4 to reach the final again after beating Thiem for the 2018 title. He will be trying to win his second title this year after triumphing in Acapulco in March.

In the women’s doubles final, Barbora Krejcikova and Katerina Siniakova, both from the Czech Republic, defeated Gabriela Dabrowski of Canada and Demi Schuurs of France 6-4, 6-3.