From da60e78bbead73dfb2f8506d3799caa93d0c37b9 Mon Sep 17 00:00:00 2001
From: Peter Taoussanis
Date: Wed, 30 May 2012 13:35:40 +0700
Subject: [PATCH] Now less choosy about when to recache appenders.
* E.g. there was a problem when changing shared-appender config. The new approach is more robust.
Signed-off-by: Peter Taoussanis
---
src/timbre/core.clj | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/timbre/core.clj b/src/timbre/core.clj
index dcf2107..3f84737 100644
--- a/src/timbre/core.clj
+++ b/src/timbre/core.clj
@@ -169,7 +169,8 @@
(add-watch
config "appender-watch"
(fn [key ref old new]
- (when-not (= (:appenders old) (:appenders new))
+ (when (not= (dissoc old :current-level)
+ (dissoc new :current-level))
(cache-appenders!))))
;;;; Define logging macros