This website uses cookies to personalize your experience. By using this website you agree to our cookie policy.

Reply To: Change size image

#48438
Ernest MarcinkoErnest Marcinko
Keymaster

Thank you!

Indeed, the size is not respected in the avatars case, I can confirm this should be adjustable. As a temporary solution I have made a small custom code snippet – but I have noted this on the bug tracker and resolve it for the upcoming release.

add_filter(
	'asp_results',
	function ( $results ) {
		foreach ( $results as $r ) {
			if ( $r->content_type === 'user' ) {
				$r->image = get_avatar_url(
					$r->id,
					array(
						'size' =>512,
					)
				);
			}
		}
		return $results;
	},
	10,
	1
);

Try adding this code via the Code Snippets plugin or to the functions.php file in your theme/child theme directory – make sure to have a full server back-up first for safety. For more details you can check the safe coding guidelines.