Question of momentum matrix element renormalization with scissor correction

In the source code “m_optic_tools.F90”, the momentum matrix element is normalized after applying the scissor correction by multiplying a correction term:
(e2+sc-e1)/(e2-e1)
It looks like this correction makes the transition dipole unchanged after the scissor correction. However, it will also break the Thomas–Reiche–Kuhn sum rule. To maintain the sum rule, the correction factor should be:
sqrt((e2+sc-e1)/(e2-e1))
I am wondering why the transition dipole should remain unchanged, even violating the TRK sum rule.