correct a variable name
This commit is contained in:
parent
de4bd2be7e
commit
d20f42b28c
|
@ -32,11 +32,11 @@ namespace AirlineServer
|
||||||
}
|
}
|
||||||
public Flight CancelFlight(Flight flight, int numberOfSeats)
|
public Flight CancelFlight(Flight flight, int numberOfSeats)
|
||||||
{
|
{
|
||||||
Flight flightToBook = this.flights.Single(f => f == flight);
|
Flight flightToCancel = this.flights.Single(f => f == flight);
|
||||||
if (flightToBook != null)
|
if (flightToCancel != null)
|
||||||
{
|
{
|
||||||
flightToBook.BookedSeats -= numberOfSeats;
|
flightToCancel.BookedSeats -= numberOfSeats;
|
||||||
return flightToBook;
|
return flightToCancel;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue