From 8715383cfd7c3fb26a3549ed7b06f4a0c308eaee Mon Sep 17 00:00:00 2001 From: Rey C Date: Sat, 16 Aug 2025 13:52:40 +0800 Subject: [PATCH] Fix: Custom avatar not shown if set default avatar Resolves #403 @polevaultweb --- includes/admin/class-wpum-avatars.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/includes/admin/class-wpum-avatars.php b/includes/admin/class-wpum-avatars.php index a67f328d..547b73a3 100644 --- a/includes/admin/class-wpum-avatars.php +++ b/includes/admin/class-wpum-avatars.php @@ -36,7 +36,9 @@ public function __construct() { if ( wpum_get_option( 'custom_avatars' ) ) { add_action( 'carbon_fields_register_fields', array( $this, 'avatar_field' ) ); - add_filter( 'get_avatar_url', array( $this, 'set_avatar_url' ), 10, 3 ); + + // Set user uploaded avatar a higher priority than the default avatar. + add_filter( 'get_avatar_url', array( $this, 'set_avatar_url' ), 11, 3 ); } if ( ! wpum_get_option( 'disable_profile_cover' ) ) {