public async Task <IActionResult> ChangeWeightAsync(Guid id, [FromBody] Dto dto) { try { var weight = dto.Validate(); await _useCase.ChangeWeightAsync(new ProductId(id), weight.Value); return(Ok()); } catch (NotFoundException <ProductId> ) { return(NotFound()); } catch (ValidationException) { return(BadRequest()); } }