Upgrade to latest Symfony HttpFoundation tag. Closes #1865.
This commit is contained in:
@@ -118,6 +118,19 @@ class UploadedFile extends File
|
||||
return $this->originalName;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the original file extension
|
||||
*
|
||||
* It is extracted from the original file name that was uploaded.
|
||||
* Then is should not be considered as a safe value.
|
||||
*
|
||||
* @return string The extension
|
||||
*/
|
||||
public function getClientOriginalExtension()
|
||||
{
|
||||
return pathinfo($this->originalName, PATHINFO_EXTENSION);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the file mime type.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user