protected function createPaymentService(Payment $payment)
    {
        return $this->getService(
            $payment,
            GatewayInfo::shouldUseAuthorize($payment->Gateway)
                ? ServiceFactory::INTENT_AUTHORIZE
                : ServiceFactory::INTENT_PURCHASE
        );
    }
protected function createPaymentService(Payment $payment)
    {
        return $this->getService(
            $payment,
            GatewayInfo::shouldUseAuthorize($payment->Gateway)
                ? ServiceFactory::INTENT_AUTHORIZE
                : ServiceFactory::INTENT_PURCHASE
        );
    }
protected function createPaymentService ( Payment $ payment ) { return $ this -> getService ( $ payment , GatewayInfo :: shouldUseAuthorize ( $ payment -> Gateway ) ? ServiceFactory :: INTENT_AUTHORIZE : ServiceFactory :: INTENT_PURCHASE ) ; }
Create a payment service. This will either return an AuthorizeService or PurchaseService, depending on
the gateway config.

@param Payment $payment
@return PaymentService

@throws InvalidConfigurationException
Create a payment service . This will either return an AuthorizeService or PurchaseService depending on the gateway config .