-
-
Notifications
You must be signed in to change notification settings - Fork 506
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No way to change avatar size #1730
Comments
Now, I know I can do |
For everyone having same issue, the temporary workaround is to use raw WP function: |
Hi True - that is a problem - I always add: function user_avatar( $size = '' ) {
$args['size'] = $size;
return get_avatar_url( $this->id, $args );
} in Class that extends TimberPost so I can |
Expected behavior
I would like to be able to change the size of the avatar pulled by
post.author.avatar
.Actual behavior
The avatar property always pulls the default gravatar size of 96x96.
Steps to reproduce behavior
Use
post.author.avatar
anywhere in the single.twigWhat version of WordPress, PHP and Timber are you using?
WordPress 4.9.6, PHP 7.2.5, Timber 1.7.1
How did you install Timber? (for example, from GitHub, Composer/Packagist, WP.org?)
WP.org
Looks like the method is just pulling the deafult avatar without allowing to set any arguments for
get_avatar_url
function:https://github.com/timber/timber/blob/master/lib/User.php#L148
The text was updated successfully, but these errors were encountered: