Local film commission in Dubrovnik, Croatia, where the hit HBO fantasy drama series "Game of Thrones" is currently shooting, had a change of heart over the filming of Cersei Lannister's (Lena Headey) controversial nude scene.

Last week, it was revealed that producers of the show were reportedly facing some pretty big problems after a significant scene - where Cersei would be forced to take a Penance Walk, completely naked, across King's Landing - was banned from filming in accordance to the Church of St. Nicholas' strict rules against public displays of sexuality.

But now, film commissioners have changed their minds and have granted permission for the scene to take place but only on the condition that Headey will not set foot in a church, TMZ reported.

To comply with the new rule, the production will have to construct fake church set for the particular scene alone.

Sources told the celebrity gossip website that the initial ruling was dropped because Dubrovnik,  which doubles as King's Landing, does not want to spoil the good relationship it has established with HBO, which has created jobs to the region.

The "Walk of Shame" scene, which was initially planned to be shot on Stradun street, between Dubrovnik cathedral and the Sponza Palace in the Croatian city, is now set to be filmed in approximately a month from now, according to Entertainment Weekly.

During the time the network and the local film commissioners had not yet reached a compromise to the problem, some entertainment news sites provided a number of options that the showrunners might take in order to make the scene happen.

For instance, David Benioff and D.B. Weiss were initially thought to look for another location where they could shot the scene unedited - an option that could have cost the production more money, Cinema Blend reported.

In addition, they were also believed to use some very expensive CGI just to include the scene in the upcoming season.

"Game of Thrones" Season 5 premieres on HBO in April 2015.