FriendsOfCake / cakephp-upload

CakePHP: Handle file uploading sans ridiculous automagic
https://cakephp-upload.readthedocs.io/
MIT License
551 stars 255 forks source link

Class 'League\Flysystem\Adapter\Local' not found #575

Closed enviniom closed 3 years ago

enviniom commented 3 years ago

Hi. I'm having this error "Class 'League\Flysystem\Adapter\Local' not found" when I'm uploading a file.

Cakephp show me than this the line generating this error

public function getFilesystem(string $field, array $settings = []): FilesystemInterface

  | {   | $adapter = new Local(Hash::get($settings, 'filesystem.root', ROOT . DS));   | $adapter = Hash::get($settings, 'filesystem.adapter', $adapter);   | if (is_callable($adapter)) {   | $adapter = $adapter();   | }

Anyone knows what do I have to do to solve it?

davidyell commented 3 years ago

As the plugin include this library in the composer file, I would guess that you've either not installed using Composer, or your autoload is broken somehow.

Try either re-installing with composer install, composer require josegonzalez/cakephp-upload or re-generating the autoload with composer dumpautoload

enviniom commented 3 years ago

I really apreciate your help, reinstaling works. Thank you so much.