Originally Posted by cjack:
Probably just note where the flat side is connected and maintain that orientation in the rewired circuit.
I like this idea. Then you don't need to worry about polarity.
Some of these schematics provided with these eBay modules must be taken with a grain of silicon (salt), but here's one that appears to match the pictured sensor module. I annotated it to show + and - of the IR LED transmitter and NPN IR photo-transistor detector. But this is just window dressing as just extending wires and maintaining orientation achieves the desired result.