Merge pull request #22573 from outis/fix-expired-link
Fix: #22572-can't access settings ("The link you followed has expired")
This commit is contained in:
commit
effa51829c
|
@ -98,9 +98,9 @@ class WC_Admin_Menus {
|
|||
$current_section = empty( $_REQUEST['section'] ) ? '' : sanitize_title( wp_unslash( $_REQUEST['section'] ) ); // WPCS: input var okay, CSRF ok.
|
||||
|
||||
// Save settings if data has been posted.
|
||||
if ( '' !== $current_section && apply_filters( "woocommerce_save_settings_{$current_tab}_{$current_section}", ! empty( $_POST ) ) ) { // WPCS: input var okay, CSRF ok.
|
||||
if ( '' !== $current_section && apply_filters( "woocommerce_save_settings_{$current_tab}_{$current_section}", ! empty( $_POST['save'] ) ) ) { // WPCS: input var okay, CSRF ok.
|
||||
WC_Admin_Settings::save();
|
||||
} elseif ( '' === $current_section && apply_filters( "woocommerce_save_settings_{$current_tab}", ! empty( $_POST ) ) ) { // WPCS: input var okay, CSRF ok.
|
||||
} elseif ( '' === $current_section && apply_filters( "woocommerce_save_settings_{$current_tab}", ! empty( $_POST['save'] ) ) ) { // WPCS: input var okay, CSRF ok.
|
||||
WC_Admin_Settings::save();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue