Mercurial > kallithea
diff rhodecode/lib/helpers.py @ 1643:bdb6fbc8265f
implements #293 gravatar link should be disabled when use_gravatar = false
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Mon, 31 Oct 2011 23:10:11 +0200 |
parents | 752b0a7b7679 |
children | 82a88013a3fd |
line wrap: on
line diff
--- a/rhodecode/lib/helpers.py Sun Oct 30 20:30:24 2011 +0200 +++ b/rhodecode/lib/helpers.py Mon Oct 31 23:10:11 2011 +0200 @@ -454,8 +454,8 @@ #============================================================================== def gravatar_url(email_address, size=30): - if not str2bool(config['app_conf'].get('use_gravatar')) or \ - email_address == 'anonymous@rhodecode.org': + if (not str2bool(config['app_conf'].get('use_gravatar')) or + not email_address or email_address == 'anonymous@rhodecode.org'): return url("/images/user%s.png" % size) ssl_enabled = 'https' == request.environ.get('wsgi.url_scheme')