Skip to content

Commit

Permalink
PLANNER-1540 Make sure a flight assignment list is never empty
Browse files Browse the repository at this point in the history
  • Loading branch information
rsynek authored and ge0ffrey committed Jun 27, 2019
1 parent 3f40ab9 commit f6d9a24
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -556,7 +556,7 @@ private void writeEmployeesView() {
Map<Integer, List<FlightAssignment>> hourToAssignmentListMap = extractHourToAssignmentListMap(employeeAssignmentList, date);
for (int departureHour = minimumHour; departureHour <= maximumHour; departureHour++) {
List<FlightAssignment> flightAssignmentList = hourToAssignmentListMap.get(departureHour);
if (flightAssignmentList != null) {
if (flightAssignmentList != null && !flightAssignmentList.isEmpty()) {
nextCell(unavailable ? unavailableStyle : defaultStyle).setCellValue(flightAssignmentList.stream()
.map(FlightAssignment::getFlight)
.map(flight -> flight.getDepartureAirport().getCode()
Expand Down

0 comments on commit f6d9a24

Please sign in to comment.