This commit is contained in:
@@ -15,21 +15,11 @@ public class CheckIncrementResult {
|
||||
private Integer remainingLimit;
|
||||
private String message;
|
||||
|
||||
public static CheckIncrementResult success(Integer countChecked, Integer remainingLimit) {
|
||||
public static CheckIncrementResult success(Integer countChecked) {
|
||||
return CheckIncrementResult.builder()
|
||||
.success(true)
|
||||
.countChecked(countChecked)
|
||||
.remainingLimit(remainingLimit)
|
||||
.message("Check count incremented successfully")
|
||||
.build();
|
||||
}
|
||||
|
||||
public static CheckIncrementResult limitExceeded(Integer remainingLimit) {
|
||||
return CheckIncrementResult.builder()
|
||||
.success(false)
|
||||
.countChecked(null)
|
||||
.remainingLimit(remainingLimit)
|
||||
.message("Check limit exceeded")
|
||||
.build();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user