You could put a PCB in the tail cap that is isolated from the cap.
Contact would go through board to negative spring.
Most zebralights are like this, lots of other brands too.
It’s nothing more than a spring soldered to a copper coated pc board.
It will depend on the design of your light but may fix your issue.