Repository navigation
Hide boosts from Plugin Licenses - #3799
Conversation
|
No actionable comments were generated in the recent review. Walkthrough
Merge Risk:
|
|
|
Overall Grade |
Security Reliability Complexity Hygiene |
Code Review Summary
| Analyzer | Status | Updated (UTC) | Details |
|---|---|---|---|
| PHP | Dec 2, 2026 3:56p.m. | Review ↗ | |
| JavaScript | Dec 2, 2026 3:56p.m. | Review ↗ |
Important
AI Review is run only on demand for your team. We're only showing results of static analysis review right now. To trigger AI Review, comment @deepsourcebot review on this thread.
There was a problem hiding this comment.
Approve (one non-blocking test note). The Plugin Licenses tab and its rows now share one eligibility filter, and boosts are excluded from both.
Reproduced before and after with a throwaway probe test (not in the PR) that registers fake add-ons on frm_installed_addons (Pro, parent-licensed, no-license, boost, separately licensed) and renders get_settings_tabs() plus license_settings(). It checks the same two things the PR's test plan does:
- Base (cad4d84): with only a boost registered, the Plugin Licenses tab is shown and has a "Some Boost" row. With a boost and a separate add-on, both get rows.
- PR head (843e894): boost only → no tab. Boost + add-on → tab with only the add-on's row. Mixed set (Pro, boost, parent-licensed, no-license, add-on) → only the add-on's row. No add-ons → no tab, same as before. An object with no
is_boostproperty still gets a row (the! empty()guard holds).
Tests run: harness PHPUnit at 843e894 (Lite, PHP 8.4, -c phpunit.xml) → --group addons 130 tests / 369 assertions OK (1 skipped, pre-existing), --filter 'Settings|FrmAddon' 164 / 723 OK (1 skipped). CI skips PHPUnit on this PR; Psalm and Typos pass.
Checked: views/addons/settings.php is only included from license_settings(), so dropping its skip is safe now the list arrives pre-filtered. The Pro check is now slug or name in both places (before: name in the tab check, slug in the view), a harmless union. FrmAddon::$is_boost already exists on master.
Non-blocking:
- No test pins the new filter. The diff adds
get_plugins_for_license_settings()but no test file, so a future edit dropping theis_boostclause would pass CI. A short case intests/phpunit/misc/test_FrmAddonsController.phpthat registers one boost and one normal add-on onfrm_installed_addonsand asserts only the normal one is returned would catch it.
Not exercised: a real boost plugin. is_boost is set at runtime from the add-ons feed (when Pro is licensed) or by the boost itself, so a Lite-only site relies on the companion boost updater change named in the PR's test plan; I did not run that or the front-end settings screen in a browser. Skills (code-review, security-review) not run; manual read of the 3-file diff, nothing user-supplied reaches output.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Non-blocking, no test pins the new filter: fixed in 7ab93c2. Added test_get_plugins_for_license_settings_excludes_boosts to tests/phpunit/misc/test_FrmAddonsController.php. It registers a boost and a normal add-on on frm_installed_addons and asserts only the normal one is returned. It fails when the is_boost clause is removed. |
There was a problem hiding this comment.
Approve (clean). My earlier non-blocking note is fixed in 7ab93c2: test_get_plugins_for_license_settings_excludes_boosts now pins the is_boost clause. Source is unchanged from the version I approved at 843e894 (the delta is the test plus a master merge); the whole 4-file diff re-read.
Tests run at 7ab93c2 (harness PHPUnit, Lite files copied over the harness checkout, PHP 8.4, -c phpunit.xml):
- New test → OK (1 test, 1 assertion). With the
|| ! empty( $plugin->is_boost )clause removed it fails ("two arrays are identical"). --group addons→ 127 tests / 366 assertions OK (1 skipped, pre-existing);--filter 'Settings|FrmAddon'→ 146 / 587 OK (1 skipped).- CI at this head: PHPUnit (7.4, 8.0, 8.2, 8.4), Psalm, Typos, Rector, Syntax all pass.
The before/after behaviour (boost-only site loses the Plugin Licenses tab; boost + separately licensed add-on shows only the add-on's row) was reproduced in my earlier review at 843e894 and the source behind it has not changed.
Not exercised: a real boost plugin (is_boost comes from the add-ons feed or the boost itself, so a Lite-only site depends on the companion boost updater change in the PR's test plan) and the front-end settings screen in a browser.
Use the same eligibility check for the Plugin Licenses tab and its rows. Boosts use separate licensing and should not prompt for an activation key.
Testing
Summary by CodeRabbit