function reserveSeats(inventory, requested) { if (!requested) return inventory; inventory.available -= requested; if (inventory.available < 0) { console.log("not enough seats"); } return inventory; }