| @@ -103,9 +103,9 @@ | ||
| 103 | 103 | * |
| 104 | 104 | * @return array<string,mixed>|bool |
| 105 | 105 | */ |
| 106 | 106 | public function save( $instance, $new_instance, $old_instance ) { |
| 107 | - if ( isset( $_POST['content-control-widget-editor-nonce'] ) && is_string( $_POST['content-control-widget-editor-nonce'] ) && wp_verify_nonce( sanitize_text_field( wp_unslash( $_POST['content-control-widget-editor-nonce'] ) ), 'content-control-widget-editor-nonce' ) ) { | |
| 107 | + if ( isset( $_POST['content-control-widget-editor-nonce'] ) && wp_verify_nonce( wp_unslash( sanitize_key( $_POST['content-control-widget-editor-nonce'] ) ), 'content-control-widget-editor-nonce' ) ) { | |
| 108 | 108 | $new_instance = parse_widget_options( $new_instance ); |
| 109 | 109 | $instance['which_users'] = $new_instance['which_users']; |
| 110 | 110 | $instance['roles'] = $new_instance['roles']; |
| 111 | 111 | |