File tree Expand file tree Collapse file tree 2 files changed +7
-10
lines changed
api/src/main/java/io/kafbat/ui Expand file tree Collapse file tree 2 files changed +7
-10
lines changed Original file line number Diff line number Diff line change @@ -53,14 +53,12 @@ static OperationResult successful() {
5353 }
5454
5555 static OperationResult error (Throwable th ) {
56- OperationError err = OperationError .UNRECOGNIZED_ERROR ;
57- switch (th ) {
58- case AccessDeniedException ignored -> err = OperationError .ACCESS_DENIED ;
59- case ValidationException ignored -> err = OperationError .VALIDATION_ERROR ;
60- case CustomBaseException ignored -> err = OperationError .EXECUTION_ERROR ;
61- case null , default -> {
62- }
63- }
56+ OperationError err = switch (th ) {
57+ case AccessDeniedException ignored -> OperationError .ACCESS_DENIED ;
58+ case ValidationException ignored -> OperationError .VALIDATION_ERROR ;
59+ case CustomBaseException ignored -> OperationError .EXECUTION_ERROR ;
60+ case null , default -> OperationError .UNRECOGNIZED_ERROR ;
61+ };
6462 return new OperationResult (false , err );
6563 }
6664
Original file line number Diff line number Diff line change @@ -157,8 +157,7 @@ private JsonType convertType(Schema schema) {
157157 case ARRAY -> new SimpleJsonType (JsonType .Type .ARRAY );
158158 case FIXED , FLOAT , DOUBLE -> new SimpleJsonType (JsonType .Type .NUMBER );
159159 case BOOLEAN -> new SimpleJsonType (JsonType .Type .BOOLEAN );
160- //case BYTES, STRING -> new SimpleJsonType(JsonType.Type.STRING);
161- default -> new SimpleJsonType (JsonType .Type .STRING );
160+ default -> new SimpleJsonType (JsonType .Type .STRING ); // BYTES, STRING and the remaining possibilities
162161 };
163162 }
164163}
You can’t perform that action at this time.
0 commit comments