Actor Ike Barinholtz attends the March Of Dimes Celebration Of Babies Luncheon honoring Jessica Alba at the Beverly Wilshire Four Seasons Hotel on December 4, 2015 in Beverly Hills, California.

The Mindy Project star Ike Barinholtz is recovering from a broken neck following a movie stunt accident.

The actor was injured five weeks ago while filming a falling stunt from a high platform for his upcoming comedy The Pact. Barinholtz fractured cervical vertebrae in his neck on impact and has been told by doctors to keep his neck stabilized until the fracture heals, Variety reported.

"We knew something was wrong right away," Barinholtz told People magazine. "It was scary and was touch and go for a while."

"I have to wear an incredibly stylish neck brace for a while as the bone heals," he continued about his recovery. "It's a cool look, especially in the summer."

The Pact, which also stars WWE Superstar John Cena and Leslie Mann, follows three parents as they attempt to stop their daughters from losing their virginity on prom night. The comedy is set to hit theaters next spring.

"After the accident, I talked to Mindy [Kaling] and we agreed that the only option was writing it into the show," he said of the sitcom's central star and creator. "Luckily, on The Mindy Project, I play a character who could break his neck falling out of his bunk bed and it's completely believable."