Skip to content

Commit 3f67eda

Browse files
committed
dont redirect to PP page if $_GET['redirect_to'] || $_POST['redirect_to']
1 parent eea366e commit 3f67eda

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
= 1.5.0 =
2+
3+
Bugs we fixed:
4+
5+
* Don't redirect user to Progress Planner dashboard if 'redirect_to' GET or POST parameter is set.
6+
17
= 1.4.2 =
28

39
Bugs we fixed:

classes/class-base.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -465,6 +465,10 @@ public function redirect_on_login( $user_login, $user ) {
465465
return;
466466
}
467467

468+
if ( ( isset( $_POST['redirect_to'] ) && '' !== $_POST['redirect_to'] ) || ( isset( $_GET['redirect_to'] ) && '' !== $_GET['redirect_to'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing -- We're not processing any data.
469+
return;
470+
}
471+
468472
// Redirect to the Progress Planner dashboard.
469473
\wp_safe_redirect( \admin_url( 'admin.php?page=progress-planner' ) );
470474
exit;

0 commit comments

Comments
 (0)