I uploaded the Urlybird 1.3.3 assignment a few days ago and my booking method was:
Update a record in the database file by putting in the customer id in the customer id field
This is how its done:
1. The book method is invoked
2. book method calls read() which retrieves the fields
3. update the fields and then call the update method supplying the new fields
Very very simple...
Well I now realize that thats wrong; since each record in the database represent a hotel and the field "size" means the number of rooms. So you cannot simply update the record by putting in the customer id. That means you are booking the whole hotel for the customer. I think I should have created another record with size 1 and the customer id and updated the original record and decrement the size field.
Am I correct? Has anybody else made the same mistake?