Skip to content

[PLTFRM-1510] Set highlight-mfa-users to Admin and Editor roles by default#85

Merged
kat3samsin merged 4 commits intoproductionfrom
fix/show-admin-editor-in-2fa-notice
Aug 15, 2025
Merged

[PLTFRM-1510] Set highlight-mfa-users to Admin and Editor roles by default#85
kat3samsin merged 4 commits intoproductionfrom
fix/show-admin-editor-in-2fa-notice

Conversation

@kat3samsin
Copy link
Copy Markdown
Contributor

Description

image

Pre-review checklist

Please make sure the items below have been covered before requesting a review:

  • This change works and has been tested locally or in Codespaces (or has an appropriate fallback).
  • This change has relevant unit tests (if applicable).
  • This change has relevant documentation additions / updates (if applicable).
  • I've created a changelog description that aligns with the provided examples.

Pre-deploy checklist

  • VIP staff: Ensure any alerts added/updated conform to internal standards (see internal documentation).

Steps to Test

  1. vip dev-env create && vip dev-env start
  2. Navigate to WP Admin > Users page
  3. Verify the notice for 2FA shows Admin and Editor instead of high privileges

@kat3samsin kat3samsin requested review from a team and Copilot August 15, 2025 00:08
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR modifies the highlight-mfa-users module to default to Admin and Editor roles instead of using configurable capabilities. The change simplifies the configuration by hard-coding the roles to DEFAULT_ADMIN_EDITOR_ROLE_SLUGS and forces the notice display to show "Administrator and Editor" rather than "high privileges".

  • Hard-codes the MFA highlighting to apply only to Admin and Editor roles
  • Removes the capability-based configuration in favor of role-based defaults
  • Forces the notice to display specific role names instead of generic "high privileges" text

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread modules/highlight-mfa-users/class-highlight-mfa-users.php Outdated
Comment thread modules/highlight-mfa-users/class-highlight-mfa-users.php
Comment thread modules/highlight-mfa-users/class-highlight-mfa-users.php Outdated
@kat3samsin kat3samsin changed the title Set highlight-mfa-users to Admin and Editor roles by default [PLTFRM-1510] Set highlight-mfa-users to Admin and Editor roles by default Aug 15, 2025
@kat3samsin kat3samsin force-pushed the fix/show-admin-editor-in-2fa-notice branch from 171e4bd to 36663f6 Compare August 15, 2025 00:22
Copy link
Copy Markdown
Contributor

@pandah3 pandah3 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@kat3samsin kat3samsin added this pull request to the merge queue Aug 15, 2025
Merged via the queue into production with commit eb5ed31 Aug 15, 2025
45 of 46 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants