Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
04/18/2013 12:36:43 AM (14 years ago)
Author:
boonebgorges
Message:

Only show the 'to disable' notice in emails if Settings is enabled

Unless Settings is enabled, these links will 404. This is not exactly a
regression, but it has become much more visible in BP 1.7, since the Settings
component is no longer enabled by default.

Fixes #4923

Props r-a-y

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-friends/bp-friends-notifications.php

    r6589 r6917  
    4040', 'buddypress' ), $initiator_name, $all_requests_link, $initiator_name, $initiator_link );
    4141
    42         $message .= sprintf( __( 'To disable these notifications please log in and go to: %s', 'buddypress' ), $settings_link );
     42        // Only show the disable notifications line if the settings component is enabled
     43        if ( bp_is_active( 'settings' ) ) {
     44                $message .= sprintf( __( 'To disable these notifications please log in and go to: %s', 'buddypress' ), $settings_link );
     45        }
    4346
    4447        /* Send the message */
    … …  
    7578', 'buddypress' ), $friend_name, $friend_name, $friend_link );
    7679
    77         $message .= sprintf( __( 'To disable these notifications please log in and go to: %s', 'buddypress' ), $settings_link );
     80        // Only show the disable notifications line if the settings component is enabled
     81        if ( bp_is_active( 'settings' ) ) {
     82                $message .= sprintf( __( 'To disable these notifications please log in and go to: %s', 'buddypress' ), $settings_link );
     83        }
    7884
    7985        /* Send the message */
Note: See TracChangeset for help on using the changeset viewer.