A lemma stated by Ke Li in [arXiv:1208.1400] has been used in e.g. [arXiv:1510.04682,arXiv:1706.04590,arXiv:1612.01464,arXiv:1308.6503,arXiv:1602.08898] for various tasks in quantum hypothesis testing, data compression with quantum side information or quantum key distribution. This lemma was originally proven in finite dimension, with a direct extension to type I von Neumann algebras. Here we show that the use of modular theory allows to give more transparent meaning to the objects constructed by the lemma, and to prove it for general von Neumann algebras. This yields immediate generalizations of e.g. [arXiv:1510.04682].