Anthony Rizzo’s home plate troubles came to an end Sunday when he hit a home run to help lift the New York Yankees, 8-5, over the Kansas City Royals, and it seems that Taylor Swift may have played a role in that.

Rizzo had not hit a home run since May 20, but the first baseman’s unusual drought came to an end in the third inning when he hit a bomb off of Royals starter Jordan Lyles.

Anthony Rizzo swings

Anthony Rizzo of the New York Yankees hits a fourth-inning home run against the Kansas City Royals at Yankee Stadium on July 23, 2023, in New York City. (Al Bello/Getty Images)

"It’s just sticking to a routine and tweaking, making little tweaks here and there," Rizzo said after the game.

YANKEES' ANTHONY RIZZO GETS SILENT TREATMENT FROM TEAMMATES AFTER BREAKING WORST SLUMP OF CAREER

"This game is such [about] feel. You could take a thousand swings, and it could go the opposite way, and you can take three swings and feel like miles and miles of success. So, it’s just all part of it."

So, what was one of the "tweaks" that made it all happen?

A Taylor Swift walk-up song.

Taylor Swift in Massachusetts

Taylor Swift performs during The Eras Tour at Gillette Stadium on May 20 in Foxborough, Massachusetts. (TAS Rights Management / Getty Images)

CLICK HERE FOR MORE SPORTS COVERAGE ON foxnews.1eye.us

"Taylor Swift, it’s her summer really," Rizzo said when asked by reporters about changing his song to Swift's "...Ready For It?" 

"She’s helping the economy in every city she goes. So, yeah, that was good."

CLICK HERE TO GET THE FOX NEWS APP

Anthony Rizzo scores a home run

Anthony Rizzo of the New York Yankees gestures to the dugout after a home run during a game against the Kansas City Royals at Yankee Stadium on July 23, 2023, in New York City. (New York Yankees/Getty Images)

Rizzo also hit an RBI double in the first and singled in the fifth before capping a 10-pitch at-bat with a single in the eighth against Scott Barlow. It was Rizzo’s 15th career four-hit game and first since Aug. 4, 2019.

The Associated Press contributed to this report.