includes/wpinv-template-functions.php 1 location
|
@@ 802-807 (lines=6) @@
|
| 799 |
|
$user_id = $invoice->get_user_id(); |
| 800 |
|
$secret = sanitize_text_field( $_GET['_wpipay'] ); |
| 801 |
|
|
| 802 |
|
if ( $secret === md5( $user_id . '::' . $invoice->get_email() . '::' . $invoice->get_key() ) ) { // valid invoice link |
| 803 |
|
$redirect_to = remove_query_arg( '_wpipay', get_permalink() ); |
| 804 |
|
|
| 805 |
|
wpinv_guest_redirect( $redirect_to, $user_id ); |
| 806 |
|
wpinv_die(); |
| 807 |
|
} |
| 808 |
|
} |
| 809 |
|
$redirect_to = is_user_logged_in() ? wpinv_get_history_page_uri() : wp_login_url( get_permalink() ); |
| 810 |
|
|
includes/wpinv-invoice-functions.php 1 location
|
@@ 1710-1715 (lines=6) @@
|
| 1707 |
|
$user_id = $invoice->get_user_id(); |
| 1708 |
|
$secret = sanitize_text_field( $_GET['_wpipay'] ); |
| 1709 |
|
|
| 1710 |
|
if ( $secret === md5( $user_id . '::' . $invoice->get_email() . '::' . $invoice_key ) ) { // valid invoice link |
| 1711 |
|
$redirect_to = remove_query_arg( '_wpipay', get_permalink() ); |
| 1712 |
|
|
| 1713 |
|
wpinv_guest_redirect( $redirect_to, $user_id ); |
| 1714 |
|
wpinv_die(); |
| 1715 |
|
} |
| 1716 |
|
} |
| 1717 |
|
} |
| 1718 |
|
} |