Hi everybody.
Suggest me please how should I properly fight with magento2 core bugs?
I have my extension which I want to be compatible with different Magento versions.
As an example there is next situation.
In the Magento 2.2.6 there is a bug which affects us reset any password, see:
https://github.com/magento/magento2/pull/19026
https://github.com/magento/magento2/commit/4e883743bec5b14271351c46e043c5f8e109d2b7
I fixed that by adding a preference for several of my clients.
I'd want to add that preference to my released plugin, but I really want it to be activated only if a client has 2.2.6 installed.
And I can't simply use
$this->productMetadata->getVersion();
inside of the preference class, because that class has changed not only one buggy function, it also has sheet of private methods and private parameters used in that function.
I'd want to have something in di.xml, but as I found it wasn't invented.
Maybe someone knows other solution.
Thanks for advise.