File tree Expand file tree Collapse file tree 2 files changed +3
-6
lines changed
openapi-validation-core/src/main/java/com/getyourguide/openapi/validation/core/log Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -31,10 +31,7 @@ private void registerLoggedMessage(OpenApiViolation openApiViolation) {
31
31
private boolean isThrottled (OpenApiViolation openApiViolation ) {
32
32
var key = buildKey (openApiViolation );
33
33
var lastLoggedTime = loggedMessages .get (key );
34
- if (lastLoggedTime == null ) {
35
- return false ;
36
- }
37
- return lastLoggedTime .plusSeconds (waitSeconds ).isAfterNow ();
34
+ return lastLoggedTime != null && lastLoggedTime .plusSeconds (waitSeconds ).isAfterNow ();
38
35
}
39
36
40
37
@ NonNull
Original file line number Diff line number Diff line change 12
12
<rule ref =" category/java/bestpractices.xml/AvoidReassigningParameters" />
13
13
<rule ref =" category/java/bestpractices.xml/CheckResultSet" />
14
14
<rule ref =" category/java/bestpractices.xml/DoubleBraceInitialization" />
15
+ <rule ref =" category/java/bestpractices.xml/NonExhaustiveSwitch" />
15
16
<rule ref =" category/java/bestpractices.xml/PrimitiveWrapperInstantiation" />
16
17
<rule ref =" category/java/bestpractices.xml/SimplifiableTestAssertion" />
17
- <rule ref =" category/java/bestpractices.xml/SwitchStmtsShouldHaveDefault" />
18
18
<rule ref =" category/java/bestpractices.xml/UnusedFormalParameter" />
19
19
<rule ref =" category/java/bestpractices.xml/UnusedLocalVariable" />
20
20
<rule ref =" category/java/bestpractices.xml/UnusedPrivateField" />
75
75
value =" org.springframework.beans.factory.annotation.Autowired, javax.inject.Inject" />
76
76
</properties >
77
77
</rule >
78
- <rule ref =" category/java/errorprone.xml/NonCaseLabelInSwitchStatement " />
78
+ <rule ref =" category/java/errorprone.xml/NonCaseLabelInSwitch " />
79
79
<rule ref =" category/java/errorprone.xml/NonStaticInitializer" />
80
80
<rule ref =" category/java/errorprone.xml/ReturnFromFinallyBlock" />
81
81
<rule ref =" category/java/errorprone.xml/UnconditionalIfStatement" />
You can’t perform that action at this time.
0 commit comments