Does this ruling apply to preaching within a church?
>>Does this ruling apply to preaching within a church?
Yes, but that has no bearing on the self-evident fact that the reproductive fitness of homosexuals is ZERO.
Per the order of precedence articulated in Romans 1 - Homosexuals are a self-inflicted social plague and part of a punitive package that is delivered upon those who worship themselves instead of their Creator.