Skip to content

Commit

Permalink
Ensure that Collaboration Tools settings save callback can run during…
Browse files Browse the repository at this point in the history
… portfolio creation.

Without the nonce, the save routine is not run, which means that
we can't be certain that all collaboration tools settings will be
switched to 'off'.

See #3248.
  • Loading branch information
boonebgorges committed Sep 26, 2023
1 parent d6f63a9 commit 22cbe8e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions wp-content/themes/openlab/lib/group-funcs.php
Original file line number Diff line number Diff line change
Expand Up @@ -1940,6 +1940,8 @@ function openlab_add_badge_button_to_profile() {
$group_type = ! empty( $_GET['type'] ) ? $_GET['type'] : null;

if ( 'portfolio' === $group_type ) {
// Necessary to ensure that the nulled collaboration tools settings are saved.
wp_nonce_field( 'openlab_collaboration_tools', 'openlab-collaboration-tools-nonce' );
return;
}

Expand Down

0 comments on commit 22cbe8e

Please sign in to comment.