Skip to content

Enhanced license validation - #2999

Open
girishpanchal30 wants to merge 2 commits into
developmentfrom
bugfix/2983
Open

Enhanced license validation#2999
girishpanchal30 wants to merge 2 commits into
developmentfrom
bugfix/2983

Conversation

@girishpanchal30

Copy link
Copy Markdown
Contributor

Closes #2983

Summary

Validated the invalid license key message when the provided license key is not in the Neve allowlist.

Checklist before the final review

  • Included E2E or unit tests for the changes in this PR.
  • Visual elements are not affected by independent changes.
  • It is at least compatible with the minimum WordPress version.
  • It loads additional script in frontend only if it is required.
  • Does not impact the Core Web Vitals.
  • In case of deprecation, old blocks are safely migrated.
  • It is usable in Widgets and FSE.
  • Copy/Paste is working if the attributes are modified.
  • PR is following the best practices

@pirate-bot

pirate-bot commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

Bundle Size Diff

Package Old Size New Size Diff
Animations 178.33 KB 178.33 KB 0 B (0.00%)
Blocks 1.65 MB 1.65 MB 0 B (0.00%)
CSS 7.83 KB 7.83 KB 0 B (0.00%)
Dashboard 172.49 KB 172.49 KB 0 B (0.00%)
Onboarding 68.14 KB 68.14 KB 0 B (0.00%)
Export Import 4.73 KB 4.73 KB 0 B (0.00%)
Pro 439.82 KB 439.82 KB 0 B (0.00%)

@pirate-bot

pirate-bot commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

Plugin build for fa35862 is ready 🛎️!

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Improves Otter Pro license activation messaging for ineligible Neve plans and preserves failure notices.

Changes:

  • Adds plan-aware license error handling.
  • Prevents reloads after failed license operations.
  • Adds PHP tests for license scenarios.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
class-dashboard-server.php Adds Neve plan validation and tailored errors.
LicenseField.js Reloads only after successful operations.
test-dashboard-server-license.php Tests activation, deactivation, and validation responses.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread plugins/otter-pro/inc/server/class-dashboard-server.php Outdated
Comment thread src/dashboard/components/LicenseField.js Outdated
Comment thread tests/test-dashboard-server-license.php Outdated
@pirate-bot

pirate-bot commented Aug 26, 2026

Copy link
Copy Markdown
Contributor

E2E Tests

Playwright Test Status: See serial and parallel matrix jobs

Performance Results serverResponse: {"q25":464.7,"q50":477.8,"q75":507.9,"cnt":10}, firstPaint: {"q25":1545.91,"q50":1758.43,"q75":1971.17,"cnt":10}, domContentLoaded: {"q25":4363,"q50":4378.14,"q75":4407.71,"cnt":10}, loaded: {"q25":4366.68,"q50":4382.17,"q75":4411.74,"cnt":10}, firstContentfulPaint: {"q25":2689.88,"q50":3046.64,"q75":3313.37,"cnt":10}, firstBlock: {"q25":21102.8,"q50":21545.05,"q75":21764.89,"cnt":10}, type: {"q25":36.17,"q50":39.68,"q75":54.16,"cnt":10}, typeWithoutInspector: {"q25":34.8,"q50":39.19,"q75":42.34,"cnt":10}, typeWithTopToolbar: {"q25":46.02,"q50":48.37,"q75":50.21,"cnt":10}, typeContainer: {"q25":18.86,"q50":19.98,"q75":23.38,"cnt":10}, focus: {"q25":174.65,"q50":178.47,"q75":182.39,"cnt":10}, inserterOpen: {"q25":55.85,"q50":57.52,"q75":58.93,"cnt":10}, inserterSearch: {"q25":35.9,"q50":38.02,"q75":40.32,"cnt":10}, inserterHover: {"q25":6.84,"q50":7.12,"q75":7.96,"cnt":20}, loadPatterns: {"q25":2243.29,"q50":2259.28,"q75":2305.96,"cnt":10}, listViewOpen: {"q25":291.71,"q50":295.56,"q75":302.96,"cnt":10}

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.

Suppressed comments (1)

Previously missed (1) — in code that hasn't changed since the last review.

tests/test-dashboard-server-license.php:14

  • This class defines OTTER_PRO_BASEFILE in set_up_before_class(), but PHP constants cannot be removed during teardown. Because PHPUnit normally runs the suite in one process, every later test will incorrectly observe Otter Pro's base file as defined, making results order-dependent (production code branches on this constant, e.g. inc/class-main.php:618). Isolate this class so the fixture cannot leak into the rest of the suite.
class Test_Dashboard_Server_License extends WP_UnitTestCase {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Ineligible Neve Personal key returns “invalid license provided” without plan context

4 participants