diff options
author | friendica <info@friendica.com> | 2014-01-03 14:18:06 -0800 |
---|---|---|
committer | friendica <info@friendica.com> | 2014-01-03 14:18:06 -0800 |
commit | f2ba6ed9982ee4b3b80331a195534f74e510d508 (patch) | |
tree | c2aa75ce5c369e9aab12f21dd26121ba98095633 | |
parent | 475b24ca9e758b257bde6f81c727178ae8b64bec (diff) | |
download | volse-hubzilla-f2ba6ed9982ee4b3b80331a195534f74e510d508.tar.gz volse-hubzilla-f2ba6ed9982ee4b3b80331a195534f74e510d508.tar.bz2 volse-hubzilla-f2ba6ed9982ee4b3b80331a195534f74e510d508.zip |
fix mimetype detection fallback
-rw-r--r-- | include/attach.php | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/include/attach.php b/include/attach.php index 0c748cba6..3eb7a9366 100644 --- a/include/attach.php +++ b/include/attach.php @@ -79,17 +79,12 @@ function z_mime_content_type($filename) { if (array_key_exists($ext, $mime_types)) { return $mime_types[$ext]; } + + } -// can't use this because we're just passing a name, e.g. not a file that can be opened -// elseif (function_exists('finfo_open')) { -// $finfo = @finfo_open(FILEINFO_MIME); -// $mimetype = @finfo_file($finfo, $filename); -// @finfo_close($finfo); -// return $mimetype; -// } - else { - return 'application/octet-stream'; - } + + return 'application/octet-stream'; + } |