public async Task <bool> Handle(HotelReservationDeleteCommand request, CancellationToken cancellationToken) { var flight = await _flightRepository.GetById(request.HotelReservationId); if (flight == null) { return(false); } await _flightRepository.DeleteById(request.HotelReservationId); return(true); }
public Task <HotelReservation> Handle(HotelReservationLoadByIdQuery request, CancellationToken cancellationToken) { return(_repository.GetById(request.HotelReservationId)); }