diff --git a/packages/Webkul/Payment/src/Payment.php b/packages/Webkul/Payment/src/Payment.php index fbd8a1ece..170bdb837 100755 --- a/packages/Webkul/Payment/src/Payment.php +++ b/packages/Webkul/Payment/src/Payment.php @@ -13,6 +13,21 @@ class Payment * @return array */ public function getSupportedPaymentMethods() + { + $paymentMethods = $this->getPaymentMethods(); + + return [ + 'jump_to_section' => 'payment', + 'html' => view('shop::checkout.onepage.payment', compact('paymentMethods'))->render() + ]; + } + + /** + * Returns all supported payment methods + * + * @return array + */ + public function getPaymentMethods() { $paymentMethods = []; @@ -28,10 +43,7 @@ class Payment } } - return [ - 'jump_to_section' => 'payment', - 'html' => view('shop::checkout.onepage.payment', compact('paymentMethods'))->render() - ]; + return $paymentMethods; } /**