MINOR Use File::get_file_extension for fallback mime-type detection

This commit is contained in:
Stig Lindqvist 2012-05-15 10:03:00 +12:00
parent ea8eb7bad4
commit 7d9cf5b365

View File

@ -211,7 +211,7 @@ class HTTP {
// Fallback to use the list from the HTTP.yml configuration and rely on the file extension
// to get the file mime-type
$ext = substr(strrchr($filename, '.'), 1);
$ext = File::get_file_extension($filename);
// Get the mime-types
$mimeTypes = Config::inst()->get('HTTP', 'MimeTypes');
// The mime type doesn't exist