mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-11-01 11:06:50 +08:00
fix(payment_link): move redirection fn to global scope for open links (#5494)
This commit is contained in:
@ -68,15 +68,15 @@ function initializeSDK() {
|
||||
setTimeout(() => {
|
||||
document.body.removeChild(shimmer);
|
||||
}, 500);
|
||||
|
||||
/**
|
||||
* Use - redirect to /payment_link/status
|
||||
*/
|
||||
function redirectToStatus() {
|
||||
var arr = window.location.pathname.split("/");
|
||||
arr.splice(0, 2);
|
||||
arr.unshift("status");
|
||||
arr.unshift("payment_link");
|
||||
window.location.href = window.location.origin + "/" + arr.join("/");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Use - redirect to /payment_link/status
|
||||
*/
|
||||
function redirectToStatus() {
|
||||
var arr = window.location.pathname.split("/");
|
||||
arr.splice(0, 2);
|
||||
arr.unshift("status");
|
||||
arr.unshift("payment_link");
|
||||
window.location.href = window.location.origin + "/" + arr.join("/");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user