Powering LED array from mains

focalist:
right, but if optically isolated, that becomes a non-concern as there is no shared ground.. correct? The optoisolator's LED doesn't share a ground with the transistor (wouldn't be isolating then, would it?).. the only thing to pass between the led and phototransistor sides is light...

I got the impression the OP was trying to save components...