Commit 25ddde7e authored by Björn Richerzhagen's avatar Björn Richerzhagen
Browse files

Prevent duplicate analyzer registrations

parent c036c435
...@@ -85,8 +85,10 @@ public class DefaultMonitor implements MonitorComponent, EventHandler, ...@@ -85,8 +85,10 @@ public class DefaultMonitor implements MonitorComponent, EventHandler,
@Override @Override
public <A extends Analyzer> void registerAnalyzer(A analyzer) { public <A extends Analyzer> void registerAnalyzer(A analyzer) {
if (!analyzers.contains(analyzer)) {
analyzers.add(analyzer); analyzers.add(analyzer);
} }
}
@Override @Override
public void log(Class<?> subject, Level level, String msg, Object... data) { public void log(Class<?> subject, Level level, String msg, Object... data) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment