wp-pay-core icon indicating copy to clipboard operation
wp-pay-core copied to clipboard

No redirect to status page if there is no action URL

Open rvdsteege opened this issue 1 year ago • 0 comments

It is possible that there is no action URL when starting a payment, e.g. Direct Debit via Mollie (for which we create the token). In this case the user will not be redirected:

https://github.com/pronamic/wp-pay-core/blob/c743a1506d01274286f51d23debf765004b17d6f/src/Plugin.php#L539-L590

@remcotolsma should we add a fallback to redirect to the payment return redirect URL?

		// Redirect to payment return redirect URL.
		$return_redirect_url = $payment->get_return_redirect_url();

		if ( ! empty( $return_redirect_url ) ) {
			wp_redirect( $return_redirect_url );

			exit;
		}

rvdsteege avatar Dec 21 '23 13:12 rvdsteege