summaryrefslogtreecommitdiff
path: root/IkiWiki
diff options
context:
space:
mode:
Diffstat (limited to 'IkiWiki')
-rwxr-xr-xIkiWiki/Plugin/comments.pm7
1 files changed, 4 insertions, 3 deletions
diff --git a/IkiWiki/Plugin/comments.pm b/IkiWiki/Plugin/comments.pm
index 2f2a515b9..bccb977e3 100755
--- a/IkiWiki/Plugin/comments.pm
+++ b/IkiWiki/Plugin/comments.pm
@@ -192,9 +192,10 @@ sub preprocess {
eval 'use Libravatar::URL';
if (! $@) {
- my $email = IkiWiki::userinfo_get($commentuser, 'email');
-
- if (defined $email) {
+ if (defined $commentopenid) {
+ $commentauthoravatar = libravatar_url(openid => $commentopenid, https => $ENV{HTTPS});
+ }
+ elsif (my $email = IkiWiki::userinfo_get($commentuser, 'email')) {
$commentauthoravatar = libravatar_url(email => $email, https => $ENV{HTTPS});
}
}