Skip to:
Content

BuddyPress.org

Opened 6 years ago

Closed 6 years ago

Last modified 3 years ago

#5223 closed enhancement (fixed)

Stop offering bp-default on new installations

Reported by: boonebgorges Owned by: boonebgorges
Milestone: 1.9 Priority: normal
Severity: normal Version:
Component: Templates Keywords: has-patch needs-testing 2nd-opinion
Cc: mercijavier@…

Description

As of 1.9, we should no longer offer bp-default as an installable theme for new installations. This will be the first step in the longer-term task of removing bp-default from the BP codebase, and spinning it out into its own theme. See #5212 for more general discussion.

My proposed solution is to bail out of registering the bp-themes theme directory unless one of the following cases obtains:

  1. The current theme is bp-default (get_stylesheet())
  2. The current theme is a child of bp-default (get_template())

If anyone thinks that this is too aggressive, we could do the above *only for new installations*. How can we tell what's a new installation? We could add something to the 1.9 upgrade routine that sets a flag in the database - something like bp_register_bp_default - to true, while that value would be set to false (or unset) for new installs.

Patch incoming for the simpler, more aggressive option.

Attachments (1)

5223.patch (1.2 KB) - added by boonebgorges 6 years ago.

Download all attachments as: .zip

Change History (9)

@boonebgorges
6 years ago

#1 @boonebgorges
6 years ago

  • Keywords has-patch needs-testing 2nd-opinion added

See 5223.patch. (Sorry for the crummy function naming - better suggestions welcome.)

#2 @DJPaul
6 years ago

One edge case not handled is if BP-Default is active on some site in the network (in multisite).

#3 @mercime
6 years ago

  • Cc mercijavier@… added

#4 @boonebgorges
6 years ago

One edge case not handled is if BP-Default is active on some site in the network (in multisite).

Thinking about this, and I'm not sure it's much of a problem. The theme directory *would* be registered on sites that are running bp-default, while it would *not* be registered elsewhere. I'll have to run some tests, but it seems like it should just work.

#5 follow-up: @boonebgorges
6 years ago

  • Owner set to boonebgorges
  • Resolution set to fixed
  • Status changed from new to closed

In 7569:

Sound the knell for the BuddyPress Default theme

bp-default is being sunsetted as of BP 1.9. The theme will continue to receive
security updates and other critical fixes, but will otherwise no longer be
under active development by the core team.

We maintain backward compatibility with sites currently using bp-default by
continuing to register the bp-themes theme directory when bp-default, or a
child theme thereof, is in use on a given site. Those sites will continue to
be able to use the theme. Installations where bp-default is not already in use
will no longer see it listed on Dashboard > Appearance.

Site administrators or developers who want to override this behavior may do so
with the 'bp_do_register_theme_directory' filter. Please note that bp-themes
will be removed altogether from BuddyPress in a future version, likely migrated
to wordpress.org/extend. See #5212.

Now cracks a noble heart. Good-night, sweet prince;
And flights of angels sing thee to thy rest.

Fixes #5223

#6 in reply to: ↑ 5 @ericlewis
6 years ago

Replying to boonebgorges:

Installations where bp-default is not already in use will no longer see it listed on Dashboard > Appearance.

I just had a case where a client switched away from a theme based on bp-default, couldn't switch back and went into a frenzy.

Not sure if this is a serious issue or not, just some feedback.

#7 @boonebgorges
6 years ago

ericlewis - Thanks for the feedback. I saw a number of reports of this very issue just over the weekend. I think it was an error in (my) judgment for us not to account for this kind of situation. I've opened a new ticket at #5325; feedback welcome.

#8 @DJPaul
3 years ago

  • Component changed from Appearance - Template Parts to Templates
Note: See TracTickets for help on using tickets.