Skip to content

Commit

Permalink
Set any pending users to pending (#40)
Browse files Browse the repository at this point in the history
* Set any pending users to pending

* include users with empty meta

* Use database update
  • Loading branch information
obenland authored Oct 27, 2024
1 parent ec713bf commit 85fb677
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions upgrade.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,14 @@ function wpau_upgrade_to_12() {
'meta_value' => true,
)
);

$wpdb->update(
$wpdb->usermeta,
array( 'meta_value' => 'pending' ),
array(
'meta_key' => 'wp-approve-user',
'meta_value' => false,
)
);
// phpcs:enable WordPress.DB
}

0 comments on commit 85fb677

Please sign in to comment.