I don't watch this stuff but I'm assuming Danny Dyer wasn't playing a prostitute so whether it's legal to work in a brothel doesn't really matter, but it is and is also legal to punt in one provided the prossie concerned isn't being coerced or exploited.
I would imagine the BBC website must have something about the storylines in it, but if somebody's been arrested as a punter then the only thing I can think of would be kerbcrawling so that would be my guess too. Obviously there's an outside chance that TV soap opera producers aren't that well versed in the Sexual Offences Act too

.