Add replacement for the buggy Magento native  environment emulation.