FakeGroupAuditService: Make auditEvents final
GitOverHttpServletIT synchronizes on this field, which results in a warning from Error Prone [1]. [1] https://errorprone.info/bugpattern/SynchronizeOnNonFinalField Change-Id: If3642194beea735656287c650f0ea0d260b5d51a
This commit is contained in:
@@ -38,6 +38,8 @@ public class FakeGroupAuditService implements GroupAuditService {
|
||||
protected final PluginSetContext<GroupAuditListener> groupAuditListeners;
|
||||
protected final PluginSetContext<AuditListener> auditListeners;
|
||||
|
||||
public final List<AuditEvent> auditEvents = new ArrayList<>();
|
||||
|
||||
public static class Module extends AbstractModule {
|
||||
@Override
|
||||
public void configure() {
|
||||
@@ -55,8 +57,6 @@ public class FakeGroupAuditService implements GroupAuditService {
|
||||
this.auditListeners = auditListeners;
|
||||
}
|
||||
|
||||
public List<AuditEvent> auditEvents = new ArrayList<>();
|
||||
|
||||
public void clearEvents() {
|
||||
auditEvents.clear();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user