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) {
3131 private boolean isThrottled (OpenApiViolation openApiViolation ) {
3232 var key = buildKey (openApiViolation );
3333 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 ();
3835 }
3936
4037 @ NonNull
Original file line number Diff line number Diff line change 1212 <rule ref =" category/java/bestpractices.xml/AvoidReassigningParameters" />
1313 <rule ref =" category/java/bestpractices.xml/CheckResultSet" />
1414 <rule ref =" category/java/bestpractices.xml/DoubleBraceInitialization" />
15+ <rule ref =" category/java/bestpractices.xml/NonExhaustiveSwitch" />
1516 <rule ref =" category/java/bestpractices.xml/PrimitiveWrapperInstantiation" />
1617 <rule ref =" category/java/bestpractices.xml/SimplifiableTestAssertion" />
17- <rule ref =" category/java/bestpractices.xml/SwitchStmtsShouldHaveDefault" />
1818 <rule ref =" category/java/bestpractices.xml/UnusedFormalParameter" />
1919 <rule ref =" category/java/bestpractices.xml/UnusedLocalVariable" />
2020 <rule ref =" category/java/bestpractices.xml/UnusedPrivateField" />
7575 value =" org.springframework.beans.factory.annotation.Autowired, javax.inject.Inject" />
7676 </properties >
7777 </rule >
78- <rule ref =" category/java/errorprone.xml/NonCaseLabelInSwitchStatement " />
78+ <rule ref =" category/java/errorprone.xml/NonCaseLabelInSwitch " />
7979 <rule ref =" category/java/errorprone.xml/NonStaticInitializer" />
8080 <rule ref =" category/java/errorprone.xml/ReturnFromFinallyBlock" />
8181 <rule ref =" category/java/errorprone.xml/UnconditionalIfStatement" />
You can’t perform that action at this time.
0 commit comments