From 8df2048d17f125e1da5795b05ad79be8cac93f11 Mon Sep 17 00:00:00 2001 From: Gunnar Wrobel
Date: Tue, 5 Oct 2010 21:11:48 +0200 Subject: [PATCH] Better style. --- components/script/horde-components.php | 6 +++--- framework/bin/install_framework | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/components/script/horde-components.php b/components/script/horde-components.php index b767f65cb..8bc171f65 100755 --- a/components/script/horde-components.php +++ b/components/script/horde-components.php @@ -8,10 +8,10 @@ if (strpos('@php_dir@', '@php_dir') === 0) { * We are heavily relying on the PEAR libraries which are not clean with regard * to E_STRICT. */ -if (version_compare(PHP_VERSION, '5.3.0', '<')) { - error_reporting(E_ALL & ~E_STRICT); -} else { +if (defined('E_DEPRECATED')) { error_reporting(E_ALL & ~E_STRICT & ~E_DEPRECATED); +} else { + error_reporting(E_ALL & ~E_STRICT); } require_once 'Horde/Autoloader/Default.php'; diff --git a/framework/bin/install_framework b/framework/bin/install_framework index 6760fd715..9bbe69ced 100755 --- a/framework/bin/install_framework +++ b/framework/bin/install_framework @@ -162,7 +162,7 @@ if (!(@include_once 'PEAR/Config.php') || !(@include_once 'PEAR/PackageFile.php')) { print_usage('PEAR libraries are not in the PHP include_path.'); } -if (version_compare(PHP_VERSION, '5.3.0', '>')) { +if (defined('E_DEPRECATED')) { error_reporting(E_ALL & ~E_DEPRECATED); } $pear_config = PEAR_Config::singleton(); -- 2.11.0