diff --git a/composer.json b/composer.json index c3e8e4a..d805f56 100644 --- a/composer.json +++ b/composer.json @@ -23,7 +23,7 @@ }, "type": "library", "require": { - "pear/console_getopt": "~1.3", + "pear/console_getopt": "~1.4", "pear/pear_exception": "~1.0" }, "replace": { diff --git a/src/PEAR.php b/src/PEAR.php index 9914a7f..b6bb191 100644 --- a/src/PEAR.php +++ b/src/PEAR.php @@ -450,7 +450,7 @@ function _checkDelExpect($error_code) } /** - * This method deletes all occurences of the specified element from + * This method deletes all occurrences of the specified element from * the expected error codes stack. * * @param mixed $error_code error code that should be deleted @@ -914,7 +914,8 @@ function __construct($message = 'unknown error', $code = null, } else { $format = $options; } - die(sprintf($format, $msg)); + printf($format, $msg); + exit($code); } if ($this->mode & PEAR_ERROR_CALLBACK && is_callable($this->callback)) { diff --git a/src/System.php b/src/System.php index a61df2d..89c53e3 100644 --- a/src/System.php +++ b/src/System.php @@ -22,7 +22,7 @@ $GLOBALS['_System_temp_files'] = array(); /** -* System offers cross plattform compatible system functions +* System offers cross platform compatible system functions * * Static functions for different operations. Should work under * Unix and Windows. The names and usage has been taken from its respectively @@ -547,7 +547,7 @@ public static function which($program, $fallback = false) * System::find("$dir -name *.php -name *.htm*"); * System::find("$dir -maxdepth 1"); * - * Params implmented: + * Params implemented: * $dir -> Start the search at this directory * -type d -> return only directories * -type f -> return only files