aboutsummaryrefslogtreecommitdiff
path: root/src/core/lombok/javac
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/lombok/javac')
-rw-r--r--src/core/lombok/javac/handlers/HandleLog.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/core/lombok/javac/handlers/HandleLog.java b/src/core/lombok/javac/handlers/HandleLog.java
index 5f0f8c90..522f8576 100644
--- a/src/core/lombok/javac/handlers/HandleLog.java
+++ b/src/core/lombok/javac/handlers/HandleLog.java
@@ -79,6 +79,11 @@ public class HandleLog {
if (loggerTopic != null && loggerTopic.trim().isEmpty()) loggerTopic = null;
if (framework.getDeclaration().getParametersWithTopic() == null && loggerTopic != null) {
annotationNode.addError(framework.getAnnotationAsString() + " does not allow a topic.");
+ loggerTopic = null;
+ }
+ if (framework.getDeclaration().getParametersWithoutTopic() == null && loggerTopic == null) {
+ annotationNode.addError(framework.getAnnotationAsString() + " requires a topic.");
+ loggerTopic = "";
}
JCFieldAccess loggingType = selfType(typeNode);