1

I am using a composer library in my custom module. The link for the library is here.

This library in turn uses https://github.com/tightenco/collect

The {Vendor}/{Module}/composer.json is

{
 "name": "vendor/moduleName",
 "description": "A module description",
 "type": "magento2-module",
 "version": "1.0.0",
 "license": [
   "OSL-3.0",
   "AFL-3.0"
  ],
"require": {
"php": ">=7.1.0",
"flagshipcompany/flagship-api-sdk": "dev-master"
},
"autoload": {
   "files": [ "registration.php" ],
   "psr-4": {
  "Vendor\\Module\\": ""
    }
  }
}

When I add the code

require BP.'/app/code/{Vendor}/{Module}/vendor/autoload.php'

to the controller, it crashes. The Exception is

 Source class "\Illuminate\Support\HigherOrderCollection" for "Illuminate\Support\HigherOrderCollectionProxy" generation does not exist.

Things that I have tried and haven't worked-

Cleared cache numerous times

Ran setup:upgrade

Ran setup:di:compile - give same error as the exception mentioned above

Any suggestions will be much appreciated. TIA!

P.S. - I am using Magneto2.3-develop and PHP 7.2

All folders have the necessary permissions

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.