Skip to content

Commit

Permalink
Fixed security nonce
Browse files Browse the repository at this point in the history
Changed operator with '&&' as per This Patchstack report
  • Loading branch information
nidhitatosaniya committed Mar 27, 2024
1 parent 7863eb2 commit 153dbb9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ public static function reset_tracker_setting( $plugin_short_name ) {
*/
public function dismiss_notice() {
$nonce = $_POST['tracking_notice'];//phpcs:ignore
if ( ! is_user_logged_in() || ! current_user_can( 'manage_options' ) || ! wp_verify_nonce( $nonce, 'tracking_notice' ) ) {
if ( ! is_user_logged_in() && ! current_user_can( 'manage_options' ) || ! wp_verify_nonce( $nonce, 'tracking_notice' ) ) {
return;
}
update_option( $this->plugin_short_name . '_allow_tracking', 'dismissed' );
Expand Down

0 comments on commit 153dbb9

Please sign in to comment.