diff mbox

[Branch,~linaro-validation/lava-server/trunk] Rev 288: Use user nickname when real name is empty

Message ID 20111109192617.3833.55990.launchpad@ackee.canonical.com
State Accepted
Headers show

Commit Message

Zygmunt Krynicki Nov. 9, 2011, 7:26 p.m. UTC
------------------------------------------------------------
revno: 288
committer: Zygmunt Krynicki <zygmunt.krynicki@linaro.org>
branch nick: lava-server
timestamp: Wed 2011-11-09 20:21:19 +0100
message:
  Use user nickname when real name is empty
modified:
  lava_server/templates/layouts/content.html


--
lp:lava-server
https://code.launchpad.net/~linaro-validation/lava-server/trunk

You are subscribed to branch lp:lava-server.
To unsubscribe from this branch go to https://code.launchpad.net/~linaro-validation/lava-server/trunk/+edit-subscription
diff mbox

Patch

=== modified file 'lava_server/templates/layouts/content.html'
--- lava_server/templates/layouts/content.html	2011-11-09 00:23:07 +0000
+++ lava_server/templates/layouts/content.html	2011-11-09 19:21:19 +0000
@@ -59,7 +59,7 @@ 
       src="{{ STATIC_URL }}lava-server/images/avatar-default-symbolic.svg"
       width="18" height="18"/>
       {% if user.is_authenticated %}
-      <a href="{% url lava.me %}" class="username">{{user.get_full_name}}</a>
+      <a href="{% url lava.me %}" class="username">{{user.get_full_name|default:user.username}}</a>
       {% else %}
       <a href="{% url django.contrib.auth.views.login %}" class="username"
         >{% trans "Guest" %}</a>