X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fexception%2FMWException.php;h=c0186f9f76aeb833bc096990fc0b91dd04c55bba;hb=e514fad81b102d15393faf5580f9de255a906d5d;hp=6fd6fb5f25293626312a9a415e69f7b2753f95ab;hpb=44aec8a00a9f0f92a746ca575b58147fea1135e5;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/exception/MWException.php b/includes/exception/MWException.php index 6fd6fb5f25..c0186f9f76 100644 --- a/includes/exception/MWException.php +++ b/includes/exception/MWException.php @@ -117,10 +117,12 @@ class MWException extends Exception { $args = array_slice( func_get_args(), 2 ); if ( $this->useMessageCache() ) { - return wfMessage( $key, $args )->text(); - } else { - return wfMsgReplaceArgs( $fallback, $args ); + try { + return wfMessage( $key, $args )->text(); + } catch ( Exception $e ) { + } } + return wfMsgReplaceArgs( $fallback, $args ); } /** @@ -139,10 +141,17 @@ class MWException extends Exception { nl2br( htmlspecialchars( MWExceptionHandler::getRedactedTraceAsString( $this ) ) ) . "
\n"; } else { + $logId = MWExceptionHandler::getLogId( $this ); + $type = get_class( $this ); return "