Novak Djokovic earned partial revenge when he beat Marco Cecchinato 6-4, 6-0 to reach the Shanghai Masters quarter-finals yesterday.

The only other time the second-seeded Djokovic played Cecchinato was in the French Open quarter-finals, where the Italian upset him in four sets.

A Masters event is a level below a Grand Slam, but Djokovic was rapt to crush Cecchinato.

“I was making him play always an extra shot,” Djokovic said. “I was aggressive when I needed to be. The second set was perfect, really.

“I wanted to start off well because I know that he battles hard and he makes you deserve every point, win every point.”

Since Djokovic lost that French Open match to Cecchinato, he’s won 28 of his 30 matches. The Serb is on a 15-match winning streak, which includes title runs at Cincinnati and the US Open. He’s bidding to win a record fourth Shanghai title this week.

Djokovic saved both break points he faced on serve in the match and successfully broke Cecchinato’s serve on four of 11 offerings.

Djokovic will take on seventh-seeded Kevin Anderson of South Africa, whom he leads 6-1 on head-to-heads. Djokovic defeated Anderson in straight sets in the Wimbledon final in July.

Anderson ousted 10th-seeded Stefanos Tsitsipas of Greece 6-4, 7-6.

Reigning champion Roger Federer was pushed all the way for the second match in a row before beating Roberto Bautista Agut. The top seed and 20-time Grand Slam winner emerged from another nervy battle to eventually defeat the 28th-ranked Spaniard 6-3, 2-6, 6-4.

He will play the Japanese eighth seed Kei Nishikori in the last eight.

The 37-year-old Federer had been forced to fight in his opening match on Wednesday, admitting that he came “very close” to defeat against Russia’s Daniil Medvedev.

Normal order appeared to have been resumed when the Swiss comfortably claimed the first set against Bautista Agut.

But the unseeded Spaniard earned a piece of personal history, winning the second set — the first time he had ever done that against the Swiss maestro.

But in the ninth game of the deciding set, Federer made the breakthrough, pumping his fist as another hard-won victory loomed into view.

Juan Martin del Potro hobbled out after hurting his right knee in an awkward fall.

The Argentine world No. 4 lost his footing at 5-5 in the first set against Croatia’s Borna Coric. The 30-year-old had lengthy treatment but conceded the match after losing the first set 7-5.

Coric, the 13th seed, faces Australia’s unseeded Matthew Ebden in the last eight.

Rising star Alexander Zverev brushed aside Australia’s new teenaged No. 1 Alex de Minaur 6-1, 6-4 to reach the quarter-finals. The 21-year-old German fourth seed was ruthless as he took the first set in just 29 minutes although his 19-year-old opponent showed more fight in the second.

Zverev ratcheted up the pressure to grab the all-important break of serve in the ninth game before closing out the match against De Minaur, who earlier this week replaced Nick Kyrgios as Australia’s top-ranked player.

Zverev will face 11th seed Kyle Edmund in the last eight after the Briton defeated Chile’s Nicolas Jarry 7-6, 6-3.

Second-seeded Caroline Garcia of France moved into the Tainjin Open quarter-finals after defeating qualifier Zhang Yuxuan 6-3, 6-4. The 16th-ranked Garcia will play sixth-seeded Petra Martic of Croatia for a semi-final berth today. Third-seeded Elise Mertens also advanced by defeating Slovakian Jana Cepelova 6-2, 6-3.

— Agencies