Commit 3d83b65b by Taylor Otwell

moved file::upload to input::upload.

parent 15043348
......@@ -154,15 +154,4 @@ class File {
return $response;
}
/**
* Move an uploaded file to storage.
*
* @param string $key
* @param string $path
* @return bool
*/
public static function upload($key, $path)
{
return array_key_exists($key, $_FILES) ? move_uploaded_file($_FILES[$key]['tmp_name'], $path) : false;
}
}
\ No newline at end of file
......@@ -87,6 +87,18 @@ class Input {
}
/**
* Move an uploaded file to permanent storage.
*
* @param string $key
* @param string $path
* @return bool
*/
public static function upload($key, $path)
{
return array_key_exists($key, $_FILES) ? move_uploaded_file($_FILES[$key]['tmp_name'], $path) : false;
}
/**
* Hydrate the input data for the request.
*
* @return void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment