Skip to:
Content

BuddyPress.org

Opened 11 years ago

Closed 11 years ago

#2718 closed enhancement (fixed)

Swap function_exists() calls to bp_is_active()

Reported by: DJPaul Owned by:
Milestone: 1.5 Priority: normal
Severity: Version:
Component: Core Keywords:
Cc: peter.westwood+buddypresstrac@…

Description (last modified by DJPaul)

Trunk currently has a mixture of function_exists() (on different function names) and bp_is_active() checks to decide if a certain part of BuddyPress is loaded. bp_is_active() was added earlier this year to eventually replace the function_exists() checks, if I remember correctly.

We should standardise on one for BuddyPress 1.3, so that core is more consistent. I suggest bp_is_active() as it prevents any third-party themes or plugins checking for the presence of functions which could possibly be removed or deprecated.

Change History (8)

#1 @westi
11 years ago

  • Cc peter.westwood+buddypresstrac@… added

Brevity is the root of all bad trac tickets :-)

Why?

#2 @DJPaul
11 years ago

  • Description modified (diff)

#3 follow-up: @DJPaul
11 years ago

Guilty as charged -- I've updated the ticket description.

#4 in reply to: ↑ 3 @westi
11 years ago

Replying to DJPaul:

Guilty as charged -- I've updated the ticket description.

Great :-)

#5 @boonebgorges
11 years ago

+1 on bp_is_active(). I've been fixing them where I see them, but I haven't done a comprehensive sweep.

#6 @djpaul
11 years ago

(In [3698]) Swap function_exists calls to bp_is_active in BP-Default. See #2718

#7 @djpaul
11 years ago

(In [4041]) Swap some more function_exists calls to bp_is_active. See #2718

#8 @djpaul
11 years ago

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

(In [4137]) Swap function_exists checks to bp_is_active. Fixes #2718

Note: See TracTickets for help on using tickets.