kohana/core — comment on commit 5fc99466c952403e3995ca74c3ecc31fae80f09a
File:  line 0
By kiall:

IMO, it's much simpler and more explicit to instead use a check for the initial request, rather than a test for two different return types..

It seems really wrong to have files return either this:

~~~
array(
'/tmp/filename1.ext',
'/tmp/filename2.ext',
);
~~~

or this

~~~
array(
'file1' => array(
'name' => 'filename1.ext',
'type' => 'image/jpeg',
'size' => 12345,
'tmp_name' => '/tmp/abcde',
'error' => 0,
),
'file2' => array(
'name' => 'filename2.ext',
'type' => 'image/jpeg',
'size' => 54321,
'tmp_name' => '/tmp/edcba',
'error' => 0,
),
);
~~~

The formats and features are completely different, and pushing $_FILES into files() seems to give no advantages...