Example #1
0
 /**
  * @param Http $request
  * @return PaymentTokenInterface|null
  */
 private function getPaymentToken(Http $request)
 {
     $publicHash = $request->getPostValue(PaymentTokenInterface::PUBLIC_HASH);
     if ($publicHash === null) {
         return null;
     }
     return $this->paymentTokenManagement->getByPublicHash($publicHash, $this->customerSession->getCustomerId());
 }