Skip to:
Content

Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#3134 closed enhancement (fixed)

Components location hardcoded

Reported by: Backie Owned by:
Milestone: 1.5 Priority: normal
Severity: Version: 1.5
Component: Core Keywords: has-patch dev-feedback
Cc:

Description

I've noticed the when loading components it only checks the in BP_PLUGIN_DIR this would limit peoples ability to extend the plugin with a separate plugin since they would need put their files into the BuddyPress directory.

Possible solution have a filter which contains the directories to check for the existence of component files.

Attachments (1)

bp-code-loader.php-directories.diff (1.9 KB) - added by Backie 8 years ago.

Download all attachments as: .zip

Change History (7)

#1 @cnorris23
8 years ago

  • Keywords dev-feedback added

There's no limitation. File loading should be handled by the individual plugin. By the time any of the BP specific hooks are fired, which plugins should be utilizing, the component loading routine has already been executed. The only exception to this is when extending the BP_Component class, but contingencies have been added there.

#2 @DJPaul
8 years ago

  • Milestone changed from Awaiting Review to 1.3

Yes. However, the required component loop shouldn't be hard-coded to the component name like that since we're iterating through those -- good spot. The plan for this area is for a future version, where we want to be smart about what parts of BuddyPress to include at run-time, based on the specific screen that is being requested (and any dependencies with that component, etc).

#3 @djpaul
8 years ago

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

(In [4165]) Fix hardcoded include path in the core bootstrap. Fixes #3134, props Backie

#4 @cnorris23
8 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

Reopening as [4165] really only fixes #3133, which Backie patched in both tickets.

#5 @djpaul
8 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

BuddyPress plugins aren't meant to be loading themselves here. bp_include remains the correct place. What's a valid use case of moving default components out of the BuddyPress folder?

#6 @cnorris23
8 years ago

There isn't one. However, just in case your first comment stood, and you did think it was a good idea, I didn't want it to get passed over.

Note: See TracTickets for help on using tickets.