Open simonmilz opened 3 days ago
Hi @simonmilz
Can you give us a little more information about the issue? Where does this happen? I've quickly checked the Core Library "vendor/laravel/src/Filesystem/FilesystemAdapter" and this is returning an array as well.
@StanBarrows you need to check the listContents
method which is being called.
Hey @simonmilz,
Could you please provide an example or some code to help us reproduce the error? I noticed that the FileSystemAdapter is returning a DirectlyListing object, while we are returning an array. However, in the current implementations where we use the package, it seems to be working with the array as well.
public function listContents(string $location, bool $deep = self::LIST_SHALLOW): DirectoryListing;
Also happy for a PR if you know the fix already.
Best regards
What happened?
I run into this issue:
Illuminate\Filesystem\FilesystemAdapter::Illuminate\Filesystem\{closure}(): Argument #1 ($attributes) must be of type League\Flysystem\StorageAttributes, array given
which kinda make sense as the
listContents
method should returniterable
instead ofarray
. The FilesystemAdapter.php in Laravel expects an array ofStorageAttributes
:Package Version
3.1
PHP Version
8.3
Laravel Version
10
Which operating systems does with happen with?
No response