Skip to:
Content

BuddyPress.org

Changeset 11939


Ignore:
Timestamp:
04/03/2018 12:36:56 AM (4 years ago)
Author:
r-a-y
Message:

Core: After r11938, undeprecate bp_is_akismet_active()

This function is still used by the Activity component's Akismet module,
and is called directly by the Nouveau template pack.

See #5351.

Location:
trunk/src/bp-core
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/bp-core-options.php

    r11938 r11939  
    690690
    691691/**
     692 * Check whether Akismet is enabled.
     693 *
     694 * @since 1.6.0
     695 *
     696 * @param bool $default Optional. Fallback value if not found in the database.
     697 *                      Default: true.
     698 * @return bool True if Akismet is enabled, otherwise false.
     699 */
     700function bp_is_akismet_active( $default = true ) {
     701
     702    /**
     703     * Filters whether or not Akismet is enabled.
     704     *
     705     * @since 1.6.0
     706     *
     707     * @param bool $value Whether or not Akismet is enabled.
     708     */
     709    return (bool) apply_filters( 'bp_is_akismet_active', (bool) bp_get_option( '_bp_enable_akismet', $default ) );
     710}
     711
     712/**
    692713 * Check whether Activity Heartbeat refresh is enabled.
    693714 *
  • trunk/src/bp-core/deprecated/3.0.php

    r11938 r11939  
    3232     */
    3333    return (bool) apply_filters( 'bp_is_group_forums_active', $is_active );
    34 }
    35 
    36 /**
    37  * Check whether Akismet is enabled.
    38  *
    39  * @since 1.6.0
    40  *
    41  * @param bool $default Optional. Fallback value if not found in the database.
    42  *                      Default: true.
    43  * @return bool True if Akismet is enabled, otherwise false.
    44  */
    45 function bp_is_akismet_active( $default = true ) {
    46 
    47     /**
    48      * Filters whether or not Akismet is enabled.
    49      *
    50      * @since 1.6.0
    51      *
    52      * @param bool $value Whether or not Akismet is enabled.
    53      */
    54     return (bool) apply_filters( 'bp_is_akismet_active', (bool) bp_get_option( '_bp_enable_akismet', $default ) );
    5534}
    5635
Note: See TracChangeset for help on using the changeset viewer.