You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4php-dev@logging.apache.org by gr...@apache.org on 2009/05/24 00:40:34 UTC

svn commit: r778051 - /incubator/log4php/trunk/src/main/php/Logger.php

Author: grobmeier
Date: Sat May 23 22:40:34 2009
New Revision: 778051

URL: http://svn.apache.org/viewvc?rev=778051&view=rev
Log:
reused isEnabledFor in log()

Modified:
    incubator/log4php/trunk/src/main/php/Logger.php

Modified: incubator/log4php/trunk/src/main/php/Logger.php
URL: http://svn.apache.org/viewvc/incubator/log4php/trunk/src/main/php/Logger.php?rev=778051&r1=778050&r2=778051&view=diff
==============================================================================
--- incubator/log4php/trunk/src/main/php/Logger.php (original)
+++ incubator/log4php/trunk/src/main/php/Logger.php Sat May 23 22:40:34 2009
@@ -340,10 +340,7 @@
 	 * @param mixed $caller caller object or caller string id
 	 */
 	public function log($priority, $message, $caller = null) {
-		if($this->repository->isDisabled($priority)) {
-			return;
-		}
-		if($priority->isGreaterOrEqual($this->getEffectiveLevel())) {
+		if($this->isEnabledFor($priority)) {
 			$this->forcedLog($this->fqcn, $caller, $priority, $message);
 		}
 	}