diff options
author | Morris Jobke <morris.jobke@gmail.com> | 2014-03-20 11:14:30 +0100 |
---|---|---|
committer | Morris Jobke <morris.jobke@gmail.com> | 2014-03-20 11:14:30 +0100 |
commit | 970878b5815da97df517688b811265531c7e152f (patch) | |
tree | cf4c73ef067b04f61ffb756b220ab5a2f8b6fe58 /lib/public | |
parent | 8a81df0f2c349416124480e80d0141ec724ffcf4 (diff) | |
parent | 51fe3b8ccd316730085f1896205e77cdf38cf57f (diff) | |
download | nextcloud-server-970878b5815da97df517688b811265531c7e152f.tar.gz nextcloud-server-970878b5815da97df517688b811265531c7e152f.zip |
Merge pull request #7818 from owncloud/logException_undefined_variable
Fix 'Undefined variable: message' in OCP\Util::logException
Diffstat (limited to 'lib/public')
-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()); |