After making controversial headlines, the Glee alum Mark Salling is arrested for possession of child pornography on Tuesday, Dec. 29, and could cost him his latest role, Us Weekly tells the story.

Adi Shankar, director of Gods and Secrets, dishes out to Us Weekly that if the 33-year-old star is convicted, he’ll cut the actor from the 2016 film.

Mark Salling Girlfriend: Did Denyse Tontz Turn 'Glee' Actor In For Child Pornography? [VIDEO]

"Today I was made aware of the serious allegations against Salling as a result of numerous media outlets hounding me as to whether he would remain in Gods and Secrets. I won't feed our growing pitchfork culture. I'm going to wait for all the facts to arrive and if in fact these allegations are true, I will immediately take action, which includes removing his scenes from the project,” Shankar shares in a statement on Wednesday, Dec. 30.

According to previous reports, law enforcement confirms with that Salling was booked at the Metropolitan Detention Center in Los Angeles after the Internet Crimes Against Children LAPD task force obtained a warrant and searched his Sunland, California home.TMZ also confirms that Law enforcement reportedly found hundreds of images.

Mark Salling Update: 'Glee' Star Gets Bailed Out Of Jail, Spotted In Car Following Arrest Of Alleged Child Pornography [VIDEO]

Meanwhile, Salling's family posted 10 percent of his bail and was seen picking him up in a black vehicle. The actor was booked at 9:47 a.m. and released around 2:30 p.m. The actor is scheduled to appear in court on Jan. 22, TMZ wrote.

Apparently, this isn’t the first time that the actor has been in trouble with the law. Us Weekly reveals that In 2013, ex-girlfriend Roxanne Gorzela filed a lawsuit in which she claimed he committed sexual battery on her by forcing her to have sex without a condom. Salling later denied the charges and the case was settled.