Skip to content

[6.x] Fix crash when the license key file lists uninstalled addons - #15651

Merged
jasonvarga merged 1 commit into
6.xfrom
fix-offline-license-uninstalled-addons
Oct 15, 2026
Merged

jasonvarga merged 1 commit into
6.xfrom
fix-offline-license-uninstalled-addons

Conversation

@joshuablum

@joshuablum joshuablum commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

When using offline license validation, the key file lists every package licensed to the site including ones that are not installed. Those entries were kept in the license response, so LicenseManager::addons() created an AddonLicense for an addon that doesn't exist and the Licensing utility crashed:

Call to a member function name() on null
src/Licensing/AddonLicense.php:24

They could also count towards addonsValid() showing a licensing alert for an addon that isn't installed.

This only keeps the key file entries for installed addons. Installed addons missing from the key file are still added as before. Online validation is unaffected, since the Outpost response only covers the installed packages sent in the request.

It also falls back to an empty list when the key file has no packages key.

Related: #15653

The offline license key file lists every package licensed to the site,
including ones that aren't installed. These ended up in the license
response and caused AddonLicense to call name() on a null addon.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@jasonvarga
jasonvarga merged commit 1f7c88f into 6.x Oct 15, 2026
66 checks passed
@jasonvarga
jasonvarga deleted the fix-offline-license-uninstalled-addons branch October 15, 2026 15:10
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.

2 participants