Problem/Motivation
The docblock in \Drupal\Core\Extension\ThemeInstallerInterface::uninstall Includes a not-entirely-accurate statement
* @throws \InvalidArgumentException
* Thrown when trying to uninstall the default theme or the admin theme.
It says the exception is thrown when trying to uninstall the default theme or the admin theme, but this exception is ALSO thrown when trying to uninstall a theme that the default/admin theme depends on.
Proposed resolution
Update the docblock so it's clear the exception will also be thrown when trying to uninstall a theme that the default theme or admin theme depends on.
Remaining tasks
User interface changes
API changes
Data model changes
Release notes snippet
Comments
Comment #2
neelam_wadhwani commentedComment #3
neelam_wadhwani commentedKindly review patch.
I have updated docblock.
Comment #4
cilefen commentedComment #5
mradcliffeAdding event tag.
The next step is to review the language in the uploaded patch.
Comment #6
martin107 commentedThis look like a good change to me.
Comment #7
alexpottThe update is not quite correct. The error is thrown for any base theme that has currently installed dependent theme is uninstalled. See the code:
Comment #8
avpadernoComment #9
alexpottWell this bit is true as well as the base theme thing. You can't uninstall the admin theme, the default theme or a theme that another theme depends on.
Comment #10
jungleComment #11
avpadernoComment #17
lendudeRe-upping @jungle's version in #10 since I like that wording better, to make clear that is the version I'm RTBCing
Comment #18
alexpottSaving issue credit.
Comment #23
alexpottCommitted and pushed 76aa51fdf9 to 10.1.x and 8295e5de71 to 10.0.x and 93ea80732b to 9.5.x and 3e872baf91 to 9.4.x. Thanks!
Backported to 9.4.x since this is a docs bug fix.
The fail was a random one.