1

This is a follow up question from this question. I want to override a Zend class using composer autoload. It used to work, but not anymore. This is content of my composer.json file:

{
  "name": "magento/sample-module-newpage",
  "description": "A Magento 2 module that creates a new page",
  "type": "magento2-module",
  "version": "1.0.0",
  "autoload": {
    "files": [ "registration.php" ,"Zend/Date.php"],
    "psr-4": {
      "Magento\\SampleNewPage\\": ""
    }
  },
  "require": {
    "php": "~5.5.0|~5.6.0|~7.0.0",
    "magento/framework": "~100.0"
  }

}

If I run this command at root of my websit (where app,vendor,... directories exist), I get this:

composer  dumpautoload
Generating autoload files

And then nothing happens. It used to add my Date.php file to end of vendor/composer/autoload_files.php. What should I do?

P.S: Mudule is installed and is working correctly.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.