Skip to content

Commit

Permalink
fix(webserver): remove useless @Valid annotation (#2231)
Browse files Browse the repository at this point in the history
  • Loading branch information
Skraye authored and tchiotludo committed Oct 11, 2023
1 parent 43f1520 commit f6e2b41
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ public HttpResponse<FlowWithSource> create(
@Post(consumes = MediaType.ALL, produces = MediaType.TEXT_JSON)
@Operation(tags = {"Flows"}, summary = "Create a flow from json object")
public HttpResponse<Flow> create(
@Parameter(description = "The flow") @Body @Valid Flow flow
@Parameter(description = "The flow") @Body Flow flow
) throws ConstraintViolationException {
return HttpResponse.ok(flowRepository.create(flow, flow.generateSource(), taskDefaultService.injectDefaults(flow)).toFlow());
}
Expand Down Expand Up @@ -380,7 +380,7 @@ public HttpResponse<FlowWithSource> update(
public HttpResponse<Flow> update(
@Parameter(description = "The flow namespace") @PathVariable String namespace,
@Parameter(description = "The flow id") @PathVariable String id,
@Parameter(description = "The flow") @Body @Valid Flow flow
@Parameter(description = "The flow") @Body Flow flow
) throws ConstraintViolationException {
Optional<Flow> existingFlow = flowRepository.findById(namespace, id);
if (existingFlow.isEmpty()) {
Expand Down

0 comments on commit f6e2b41

Please sign in to comment.