From 181bf8b43411ff309517ca6ca804fc34dae1e13a Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Sat, 4 Oct 2014 12:27:26 -0400 Subject: slf4j: Test best practices. --- .../main/java/com/tavianator/sangria/slf4j/Slf4jLoggerProvider.java | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'sangria-slf4j/src/main/java/com/tavianator/sangria') diff --git a/sangria-slf4j/src/main/java/com/tavianator/sangria/slf4j/Slf4jLoggerProvider.java b/sangria-slf4j/src/main/java/com/tavianator/sangria/slf4j/Slf4jLoggerProvider.java index 916f2b9..bcb7e8b 100644 --- a/sangria-slf4j/src/main/java/com/tavianator/sangria/slf4j/Slf4jLoggerProvider.java +++ b/sangria-slf4j/src/main/java/com/tavianator/sangria/slf4j/Slf4jLoggerProvider.java @@ -19,6 +19,7 @@ package com.tavianator.sangria.slf4j; import javax.inject.Singleton; +import com.google.inject.Inject; import com.google.inject.spi.InjectionPoint; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -34,6 +35,10 @@ import com.tavianator.sangria.contextual.ContextSensitiveProvider; */ @Singleton class Slf4jLoggerProvider implements ContextSensitiveProvider { + @Inject + Slf4jLoggerProvider() { + } + @Override public Logger getInContext(InjectionPoint injectionPoint) { return LoggerFactory.getLogger(injectionPoint.getDeclaringType().getRawType()); -- cgit v1.2.3