moved file::upload to input::upload.
This commit is contained in:
parent
15043348c1
commit
3d83b65bb7
|
@ -154,15 +154,4 @@ public static function download($path, $name = null)
|
||||||
return $response;
|
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;
|
|
||||||
}
|
|
||||||
}
|
}
|
|
@ -86,6 +86,18 @@ public static function file($key = null, $default = null)
|
||||||
return Arr::get($_FILES, $key, $default);
|
return Arr::get($_FILES, $key, $default);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 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.
|
* Hydrate the input data for the request.
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in New Issue