Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
08/04/2017 06:17:18 PM (4 years ago)
Author:
r-a-y
Message:

Avatars: If requested width is larger than our thumb width, set avatar size to 'full'.

After r11614, fixes a regression where avatars might appear blurry when
fetching a post author's avatar.

Props coach-afrane.

Fixes #7578 (trunk).

File:
1 edited

Legend:

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

    r11638 r11670  
    14011401    $args['html']    = false;
    14021402
     1403    // Use the 'full' type if size is larger than BP's thumb width.
     1404    if ( (int) $args['size'] > bp_core_avatar_thumb_width() ) {
     1405        $args['type'] = 'full';
     1406    }
     1407
    14031408    // Get the BuddyPress avatar URL.
    14041409    if ( $bp_avatar = bp_core_fetch_avatar( $args ) ) {
Note: See TracChangeset for help on using the changeset viewer.