File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed
examples/java/java-booking-03_preserve_whole_object/src/main/java/tv/codely/booking Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -10,8 +10,7 @@ public final class Booking {
1010 private final CustomerName customerName ;
1111 private final EmailAddress customerEmail ;
1212 private final BookingType bookingType ;
13- private final DiscountType discountType ;
14- private final DiscountValue discountValue ;
13+ private final Discount discount ;
1514 private final Tax tax ;
1615
1716 public Booking (
@@ -29,8 +28,7 @@ public Booking(
2928 this .customerName = customer .name ();
3029 this .customerEmail = customer .emailAddress ();
3130 this .bookingType = bookingType ;
32- this .discountType = discount .type ();
33- this .discountValue = discount .value ();
31+ this .discount = discount ;
3432 this .tax = tax ;
3533 }
3634
You can’t perform that action at this time.
0 commit comments