From 1848657023d797964ac464a89cb06f116f04e6f7 Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Mon, 6 Jul 2009 13:34:16 -0600 Subject: [PATCH] mime_magic extension is deprecated --- framework/Mime/lib/Horde/Mime/Magic.php | 5 ----- framework/Mime/package.xml | 3 ++- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/framework/Mime/lib/Horde/Mime/Magic.php b/framework/Mime/lib/Horde/Mime/Magic.php index 80ff10afe..65c5b26c7 100644 --- a/framework/Mime/lib/Horde/Mime/Magic.php +++ b/framework/Mime/lib/Horde/Mime/Magic.php @@ -151,7 +151,6 @@ class Horde_Mime_Magic */ static public function analyzeFile($path, $magic_db = null) { - /* If the PHP Mimetype extension is available, use that. */ if (Horde_Util::extensionExists('fileinfo')) { $res = empty($magic_db) ? @finfo_open(FILEINFO_MIME) @@ -174,10 +173,6 @@ class Horde_Mime_Magic } } - if (Horde_Util::extensionExists('mime_magic')) { - return trim(mime_content_type($path)); - } - return false; } diff --git a/framework/Mime/package.xml b/framework/Mime/package.xml index c23b62c87..d3032dffe 100644 --- a/framework/Mime/package.xml +++ b/framework/Mime/package.xml @@ -31,7 +31,8 @@ http://pear.php.net/dtd/package-2.0.xsd"> alpha LGPL - * Use Gnumeric to display MS Excel documents. + * Remove support for deprecated mime_magic module. + * Use Gnumeric to display MS Excel documents. * Use AbiWord to display MS Word documents (Request #8011). * Add support for decoding IDN (RFC 3490) names (Request #5836). * Initial package. -- 2.11.0