-
Notifications
You must be signed in to change notification settings - Fork 2k
Closed
Labels
bugVerified issues on the current code behavior or pull requests that will fix themVerified issues on the current code behavior or pull requests that will fix them
Description
PHP Version
7.3, 7.4, 8.0, 8.1
CodeIgniter4 Version
4.2.1
CodeIgniter4 Installation Method
Composer (as dependency to an existing project)
Which operating systems have you tested for this bug?
macOS, Linux
Which server did you use?
fpm-fcgi
Database
MariaDB 10.8
What happened?
When I'm trying to create FileCollection object from 2 or more files paths (not directories), passed in the __constructor, only first file is added. Because in FileCollection->add() method uses return $this->addFile($path); instead of $this->addFile($path); that ends the execution of the foreach loop
Steps to Reproduce
$object = new FileCollection(['/path/to/file', '/path/to/other-file']);
Expected Output
An object containing all passed files
Anything else?
No response
Metadata
Metadata
Assignees
Labels
bugVerified issues on the current code behavior or pull requests that will fix themVerified issues on the current code behavior or pull requests that will fix them