handleOnChange(formValues) {
        
        const allowsInternationalOrders = this.props && this.props.allowsInternationalOrders ? this.props.allowsInternationalOrders : false;
        const authorCountry = this.props && this.props.authorCountry ? this.props.authorCountry : null;
        const maxQuantity = this.props && this.props.maxQuantity ? this.props.maxQuantity : null;

        // Should not update the line items through onFetchTransactionLineItems if
        // listing does not allow international orders and if max transaction quantity is limited to 1
        // or if maxQuantity does not exist
        const shouldNotUpdateLineItems = !allowsInternationalOrders && (!maxQuantity || maxQuantity === 1);
        
        const country = formValues.values && formValues.values.country && allowsInternationalOrders ? formValues.values.country : 
            !allowsInternationalOrders && authorCountry ? authorCountry : null;
        const quantity = formValues.values && formValues.values.quantity ? formValues.values.quantity : null;
        
        const listingId = this.props.listingId;
        const isOwnListing = this.props.isOwnListing;

        if (this._isMounted && !shouldNotUpdateLineItems && country && quantity && !this.props.fetchLineItemsInProgress) {
            this.props.onFetchTransactionLineItems({
                bookingData: {
                    authorCountry,
                    shippingCountry: country,
                    quantity
                },
                listingId,
                isOwnListing,
            });
        }
    }
// the values here to the bookingData object.
the values here to the bookingData object.
the values here to the bookingData object .
handleOnChange(formValues) {
        const allowsInternationalOrders = this.props && this.props.allowsInternationalOrders ? this.props.allowsInternationalOrders : false;
        const authorCountry = this.props && this.props.authorCountry ? this.props.authorCountry : null;
        const maxQuantity = this.props && this.props.maxQuantity ? this.props.maxQuantity : null;
        const shouldNotUpdateLineItems = !allowsInternationalOrders && (!maxQuantity || maxQuantity === 1);
        const country = formValues.values && formValues.values.country && allowsInternationalOrders ? formValues.values.country : 
            !allowsInternationalOrders && authorCountry ? authorCountry : null;
        const quantity = formValues.values && formValues.values.quantity ? formValues.values.quantity : null;
        const listingId = this.props.listingId;
        const isOwnListing = this.props.isOwnListing;
        if (this._isMounted && !shouldNotUpdateLineItems && country && quantity && !this.props.fetchLineItemsInProgress) {
            this.props.onFetchTransactionLineItems({
                bookingData: {
                    authorCountry,
                    shippingCountry: country,
                    quantity
                },
                listingId,
                isOwnListing,
            });
        }
    }
handleOnChange ( formValues ) { const allowsInternationalOrders = this . props && this . props . allowsInternationalOrders ? this . props . allowsInternationalOrders : false ; const authorCountry = this . props && this . props . authorCountry ? this . props . authorCountry : null ; const maxQuantity = this . props && this . props . maxQuantity ? this . props . maxQuantity : null ; const shouldNotUpdateLineItems = ! allowsInternationalOrders && ( ! maxQuantity || maxQuantity === 1 ) ; const country = formValues . values && formValues . values . country && allowsInternationalOrders ? formValues . values . country : ! allowsInternationalOrders && authorCountry ? authorCountry : null ; const quantity = formValues . values && formValues . values . quantity ? formValues . values . quantity : null ; const listingId = this . props . listingId ; const isOwnListing = this . props . isOwnListing ; if ( this . _isMounted && ! shouldNotUpdateLineItems && country && quantity && ! this . props . fetchLineItemsInProgress ) { this . props . onFetchTransactionLineItems ( { bookingData : { authorCountry , shippingCountry : country , quantity } , listingId , isOwnListing , } ) ; } }
the values here to the bookingData object.
the values here to the bookingData object .
// Should not update the line items through onFetchTransactionLineItems if // listing does not allow international orders and if max transaction quantity is limited to 1 // or if maxQuantity does not exist