[LOGBack-dev] svn commit: r496 - logback/trunk/logback-classic/src/main/java/ch/qos/logback/classic/pattern

noreply.seb at qos.ch noreply.seb at qos.ch
Wed Aug 30 16:43:17 CEST 2006


Author: seb
Date: Wed Aug 30 16:43:17 2006
New Revision: 496

Modified:
   logback/trunk/logback-classic/src/main/java/ch/qos/logback/classic/pattern/MessageConverter.java

Log:
MessageConverter needs to check what message it needs to return.

Modified: logback/trunk/logback-classic/src/main/java/ch/qos/logback/classic/pattern/MessageConverter.java
==============================================================================
--- logback/trunk/logback-classic/src/main/java/ch/qos/logback/classic/pattern/MessageConverter.java	(original)
+++ logback/trunk/logback-classic/src/main/java/ch/qos/logback/classic/pattern/MessageConverter.java	Wed Aug 30 16:43:17 2006
@@ -20,6 +20,9 @@
 
   public String convert(Object event) {
     LoggingEvent le = (LoggingEvent) event;
+    if (le.getFormattedMessage() == null) {
+    	return le.getMessage();
+    }
     return le.getFormattedMessage();
   }
 



More information about the logback-dev mailing list