If got a problem with the Upload class (Version 1.6 says oil. But I downloaded it two days ago.). I'm running more or less the same code as in Version 1.5:
I select only one file (a simple test.png) which is uploaded and named to something random. But another file created too. With the same name. The file gets named accordingly suffixed with _1. The file takes up 0 bytes (says Finder).
Is this a known issue? Or just me not reading the releases notes?
I disabled auto_process in the config array I use as an argument in the Upload::process() call. The files are saved correctly, but still two files with the same name are created. It's like the auto_process value is ignored.
I had to disable auto_process in the upload.php-config file.
Same problem occurs here...i have 'auto_process' set to true in general config file...if i use new set of configs(with 'auto_process' => false) while uploading it still calls process twice and uploading a ghost file.
composer.json says im using "fuelphp/upload": "2.0"
You can not set "auto_process" to false by passing config, you have to change it in the config file. It is a flag checked in the class init, which is processed as soon as the class loads. If you intend to use Upload with a custom config and not with the config from the upload.php config file, you should set auto_process to false.