Skip to:
Content

BuddyPress.org

Changeset 13500


Ignore:
Timestamp:
06/10/2023 06:22:42 AM (9 months ago)
Author:
imath
Message:

Core, Activity: remove more never used inited variables in functions

Props upadalavipul, kajalgohel, viralsampat

Fixes #8892
Closes https://github.com/buddypress/buddypress/pull/115

Location:
trunk/src
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-activity/bp-activity-notifications.php

    r13441 r13500  
    4343
    4444            /* translators: %s: the current user display name */
    45             $title  = sprintf( __( '@%s Mentions', 'buddypress' ), bp_get_loggedin_user_username() );
     45            $text   = sprintf( __( '@%s Mentions', 'buddypress' ), bp_get_loggedin_user_username() );
    4646            $amount = 'single';
    4747
     
    5858        case 'update_reply':
    5959            $link   = bp_get_notifications_permalink();
    60             $title  = __( 'New Activity reply', 'buddypress' );
     60            $text   = __( 'New Activity reply', 'buddypress' );
    6161            $amount = 'single';
    6262
     
    7777        case 'comment_reply':
    7878            $link   = bp_get_notifications_permalink();
    79             $title  = __( 'New Activity comment reply', 'buddypress' );
     79            $text   = __( 'New Activity comment reply', 'buddypress' );
    8080            $amount = 'single';
    8181
  • trunk/src/bp-activity/bp-activity-template.php

    r13493 r13500  
    31913191function bp_activity_can_comment() {
    31923192    global $activities_template;
    3193     $bp = buddypress();
    31943193
    31953194    // Determine ability to comment based on activity type name.
  • trunk/src/bp-core/bp-core-buddybar.php

    r13443 r13500  
    120120 */
    121121function bp_core_create_nav_link( $args = '', $component = 'members' ) {
    122     $bp = buddypress();
    123 
    124122    $defaults = array(
    125123        'component_id'            => '',    // The component ID registering this nav item.
     
    539537 */
    540538function bp_core_create_subnav_link( $args = '', $component = 'members' ) {
    541     $bp = buddypress();
    542 
    543539    $r = bp_parse_args(
    544540        $args,
  • trunk/src/bp-core/classes/class-bp-block.php

    r13321 r13500  
    196196            if ( ! isset( $this->registered_scripts['editor_script'] ) || ! $this->registered_scripts['editor_script'] ) {
    197197                $this->block = new WP_Error( 'script_registration_error', __( 'The required `editor_script` could not be registered.', 'buddypress' ) );
     198
     199                // Register the styles.
    198200            } else {
    199                 // Register the styles.
    200                 $registered_styles = array();
    201201
    202202                foreach ( array( 'editor_style', 'style' ) as $style_handle_key ) {
  • trunk/src/bp-core/classes/class-bp-core-bp-nav-backcompat.php

    r13311 r13500  
    217217     */
    218218    protected function get_nav( $offset ) {
    219         $bp = buddypress();
    220 
    221219        $component_nav = $this->get_component_nav( $offset );
    222220        $primary_nav   = $component_nav->get_primary( array( 'slug' => $offset ), false );
  • trunk/src/bp-core/classes/class-bp-invitation-manager.php

    r13172 r13500  
    170170     */
    171171    public function send_invitation_by_id( $invitation_id = 0, $args = array() ) {
    172         $updated = false;
    173 
    174172        $invitation = new BP_Invitation( $invitation_id );
    175173
     
    328326     */
    329327    public function send_request_notification_by_id( $request_id = 0, $args = array() ) {
    330         $updated = false;
    331 
    332328        $request = new BP_Invitation( $request_id );
    333329
  • trunk/src/bp-core/classes/class-bp-media-extractor.php

    r13414 r13500  
    520520    protected function extract_embeds( $richtext, $plaintext, $extra_args = array() ) {
    521521        $data   = array( 'has' => array( 'embeds' => 0 ), 'embeds' => array() );
    522         $embeds = array();
    523522
    524523        if ( ! function_exists( '_wp_oembed_get_object' ) ) {
Note: See TracChangeset for help on using the changeset viewer.