Return immutable list when getting order items
@@ -76,6 +76,6 @@ public class Order {
}
public List<OrderItem> getOrderItems() {
- return orderItems;
+ return Collections.unmodifiableList(orderItems);
}
}
