Permalink
Browse files

Log only if logger exist and silence flag has not been set

  • Loading branch information...
1 parent 8ffd00d commit 67dcf7ada7c953149c4e338d08f4f7b9e402e340 @ccocchi ccocchi committed Feb 2, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/action_dispatch/session/libmemcached_store.rb
@@ -60,7 +60,7 @@ def with_lock(env, default)
@mutex.lock if env['rack.multithread']
yield
rescue Memcached::Error => e
- logger.error e.error
+ logger.error(e.message) if logger && !silence?
default
ensure
@mutex.unlock if @mutex.locked?

0 comments on commit 67dcf7a

Please sign in to comment.