Merge pull request #6438 from owncloud/core-logexceptionfix
Do not use L10n when logging exceptions
This commit is contained in:
commit
275d666d26
|
@ -292,9 +292,8 @@ class OC_Template extends \OC\Template\Base {
|
|||
if (!empty($hint)) {
|
||||
$hint = '<pre>'.$hint.'</pre>';
|
||||
}
|
||||
$l = OC_L10N::get('lib');
|
||||
while (method_exists($exception, 'previous') && $exception = $exception->previous()) {
|
||||
$error_msg .= '<br/>'.$l->t('Caused by:').' ';
|
||||
$error_msg .= '<br/>Caused by:' . ' ';
|
||||
if ($exception->getCode()) {
|
||||
$error_msg .= '['.$exception->getCode().'] ';
|
||||
}
|
||||
|
|
|
@ -103,9 +103,8 @@ class Util {
|
|||
}
|
||||
|
||||
// include cause
|
||||
$l = \OC_L10N::get('lib');
|
||||
while (method_exists($ex, 'getPrevious') && $ex = $ex->getPrevious()) {
|
||||
$message .= ' - '.$l->t('Caused by:').' ';
|
||||
$message .= ' - Caused by:' . ' ';
|
||||
$message .= $ex->getMessage();
|
||||
if ($ex->getCode()) {
|
||||
$message .= '[' . $ex->getCode() . '] ';
|
||||
|
|
Loading…
Reference in New Issue