Opened 6 years ago
Closed 6 years ago
#7758 closed defect (bug) (fixed)
PHP notices on deactivation
Reported by: | Mamaduka | Owned by: | djpaul |
---|---|---|---|
Milestone: | 3.0 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Core | Keywords: | has-patch |
Cc: |
Description
When deactivating plugin bp_check_theme_template_pack_dependency()
is causing PHP notices/warnings.
Cause: On deactivation BP bails early in BuddyPress::setup_actions()
and doesn't register theme packages.
I think the easiest way to fix this will be to add a check to bp_check_theme_template_pack_dependency()
function and bail early as well.
P.S. Happy to provide a patch.
Attachments (2)
Change History (6)
#2
@
6 years ago
The first patch is too specific to an implementation. If we change that internal structure of the global, we have to update everywhere we check the path directly. The helper function in the second patch is consistent with how we handle this sort of situation elsewhere already. Thanks for the patch!
Attached two versions of the patch. Personally I like first solution, make easier to understand code logic IMO. Second one needs more context to understand while we're bailing early on BP deactivation.