Applications – How to transfer IR remote control codes to a phone without learning support?

My current Android phone has an infrared sensor and I can use it to control some devices. But unlike my old Android phone, it does not support learning new IR codes to act as a universal remote. Fortunately, I still have my old phone with me. Is it possible to transfer the IR code files learned by my old device to a new device?

How do I do this, if it is possible?