diff options
author | Thomas Tanghus <thomas@tanghus.net> | 2014-03-20 10:23:40 +0100 |
---|---|---|
committer | Thomas Tanghus <thomas@tanghus.net> | 2014-03-20 10:23:40 +0100 |
commit | 51fe3b8ccd316730085f1896205e77cdf38cf57f (patch) | |
tree | fa1245a7261341b90eb187f995e3d205875e34c4 /lib/public/util.php | |
parent | 3aa8647634d02ee97c8e31119049af506b9918dd (diff) | |
download | nextcloud-server-51fe3b8ccd316730085f1896205e77cdf38cf57f.tar.gz nextcloud-server-51fe3b8ccd316730085f1896205e77cdf38cf57f.zip |
Fix 'Undefined variable: message' in OCP\Util::logException
Diffstat (limited to 'lib/public/util.php')
-rw-r--r-- | lib/public/util.php | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/lib/public/util.php b/lib/public/util.php index 585c5d22634..a159bf1423c 100644 --- a/lib/public/util.php +++ b/lib/public/util.php @@ -89,14 +89,11 @@ class Util { */ public static function logException( $app, \Exception $ex ) { $class = get_class($ex); - if ($class !== 'Exception') { - $message = $class . ': '; - } - $message .= $ex->getMessage(); + $message = $class . ': ' . $ex->getMessage(); if ($ex->getCode()) { $message .= ' [' . $ex->getCode() . ']'; } - \OCP\Util::writeLog($app, 'Exception: ' . $message, \OCP\Util::FATAL); + \OCP\Util::writeLog($app, $message, \OCP\Util::FATAL); if (defined('DEBUG') and DEBUG) { // also log stack trace $stack = explode("\n", $ex->getTraceAsString()); |