Jesse Tyler Ferguson replaced Ty Burrell as officiant at Sarah Hyland's wedding

Jesse Tyler Ferguson stepped in to serve as the officiant at Sarah Hyland's wedding after their Modern Family co-star Ty Burrell dropped out due to a family emergency.

The actor served as the officiant when his former co-star married radio personality Wells Adams at a winery near Santa Barbara in California earlier this month.

In an interview with Entertainment Tonight, Ferguson revealed that Burrell, who played Hyland's onscreen father in Modern Family, was originally supposed to marry the bride and groom but he had to bow out of the role 12 days before the ceremony.

"I don't know if people know this, but Ty Burrell was meant to do it, and there was a family emergency," Ferguson said. "So, I got a phone call 12 days before the wedding, and that's why Ty wasn't there, he had stuff going on.

"I was like, 'Well, no pressure, this is my first time, and then it's going to be a wedding, and it's going to be in Vogue magazine, and there's also going to be paparazzi shots of me from a helicopter, officiating, no pressure.'"

After he agreed to replace Burrell, Ferguson asked his co-star for pointers on what he should say during the service.

"I did call Ty, 'Like what are some of your bullet points that you were going to talk about, because I need to fast-track this,'" he explained. "He hadn't written anything up, but he had some ideas, and I was like, 'Oh, this is all really good. This is a jumping-off place.' I was honoured to do it. Very happy to understudy Ty Burrell."

The 46-year-old added that he kept the ceremony "funny" and "light-hearted" because the bride and groom aren't "serious people" but he also made sure he didn't go overboard with the jokes.

Fellow Modern Family stars Julie Bowen, Sofia Vergara, Ariel Winter, and Nolan Gould were also guests at the ceremony, and Ferguson said it was "so good to see everyone" together once again.