[buddypress-trac] [BuddyPress Trac] #6853: Autoload BP classes

buddypress-trac noreply at wordpress.org
Fri Mar 11 14:39:42 UTC 2016


#6853: Autoload BP classes
--------------------------+------------------
 Reporter:  boonebgorges  |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  2.6
Component:  API           |     Version:
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |
--------------------------+------------------

Comment (by needle):

 Replying to [comment:17 boonebgorges]:
 > I had a feeling that this would probably happen. In general I'd suggest
 using a unique prefix for your class/function names. But it's not
 acceptable for us to fatal like this. The simple answer is to do a
 `file_exists()` check before we attempt to autoload. I'd originally
 avoided this to minimize I/O, but I just did some testing and the added
 overhead is negligible.

 Thanks, the latest commit fixes the issue for me. I could rename my
 classes, but I have no idea what the knock-on effects might be. Will
 follow the naming advice in future.

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6853#comment:19>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list