Closed adelowo closed 6 years ago
This would be a silly idea to implement if code doesn't change but i have that laid out already.
We could introduce variadic arguments to those interfaces (esp. the FileNameGenerator
)
As an example, this (https://github.com/Gargron/fileupload/blob/master/src/FileUpload/FileNameGenerator/MD5.php#L37-L63) would become this
public function getFileName(...$args)
{
list($source_name, $type, $tmp_name, $index, $content_range, $upload) = $args;
//previous code left untouched
//we lose IDE typehinting for `$upload` but we can always annotate that ?
}
Another thing is the library makes use of phpunit 3.7
. 4.8
used to be the most stable version but support has ended. https://thephp.cc/news/2017/02/migrating-to-phpunit-6
Right now, 5.3 is still supported. https://github.com/Gargron/fileupload/blob/master/.travis.yml#L4-L9
From http://php.net/eol.php
I have thought of this and would want to pin the minimum version to
5.6
(Update7.0
).Hey @Gargron , i most likely would need your opinions on this.