models/oxpspaymorrowoxpaymentgateway.php
protected function _handleOrderResponseErrors( $oPmResponseHandler )
    {
        $aInitDataForPaymentStep = array();

        // If order was declined, collect declination fields and unset error code ("unexpected" error)
        if ( $oPmResponseHandler->wasDeclined() ) {
            $aInitDataForPaymentStep = (array) $oPmResponseHandler->getDeclinationDataFromResponse();
        }

        $aErrorsData = (array) $oPmResponseHandler->getErrorDataFromResponse();

        // If there are errors add those to the data array
        if ( !empty( $aErrorsData ) ) {
            $aInitDataForPaymentStep = array_merge( $aInitDataForPaymentStep, $aErrorsData );
        }

        // If order declination data or errors were present, save the data to session
        if ( !empty( $aInitDataForPaymentStep ) ) {
            $oPmResponseHandler->setErrorCode( null );
            $this->_setSessionInitData( $aInitDataForPaymentStep );
        }
    }
protected function _handleOrderResponseErrors( $oPmResponseHandler )
    {
        $aInitDataForPaymentStep = array();

        // If order was declined, collect declination fields and unset error code ("unexpected" error)
        if ( $oPmResponseHandler->wasDeclined() ) {
            $aInitDataForPaymentStep = (array) $oPmResponseHandler->getDeclinationDataFromResponse();
        }

        $aErrorsData = (array) $oPmResponseHandler->getErrorDataFromResponse();

        // If there are errors add those to the data array
        if ( !empty( $aErrorsData ) ) {
            $aInitDataForPaymentStep = array_merge( $aInitDataForPaymentStep, $aErrorsData );
        }

        // If order declination data or errors were present, save the data to session
        if ( !empty( $aInitDataForPaymentStep ) ) {
            $oPmResponseHandler->setErrorCode( null );
            $this->_setSessionInitData( $aInitDataForPaymentStep );
        }
    }
protected function _handleOrderResponseErrors ( $ oPmResponseHandler ) { $ aInitDataForPaymentStep = array ( ) ; // If order was declined, collect declination fields and unset error code ("unexpected" error) if ( $ oPmResponseHandler -> wasDeclined ( ) ) { $ aInitDataForPaymentStep = ( array ) $ oPmResponseHandler -> getDeclinationDataFromResponse ( ) ; } $ aErrorsData = ( array ) $ oPmResponseHandler -> getErrorDataFromResponse ( ) ; // If there are errors add those to the data array if ( ! empty ( $ aErrorsData ) ) { $ aInitDataForPaymentStep = array_merge ( $ aInitDataForPaymentStep , $ aErrorsData ) ; } // If order declination data or errors were present, save the data to session if ( ! empty ( $ aInitDataForPaymentStep ) ) { $ oPmResponseHandler -> setErrorCode ( null ) ; $ this -> _setSessionInitData ( $ aInitDataForPaymentStep ) ; } }
Check order response for declination status and fields and error fields.
Set all relevant fields to session.
The session data is used to go with redirection to payment step and used to initialize payment forms.

@param OxpsPaymorrowResponseHandler $oPmResponseHandler
Check order response for declination status and fields and error fields . Set all relevant fields to session . The session data is used to go with redirection to payment step and used to initialize payment forms .