diff options
| author | sostler <sbostler@gmail.com> | 2010-01-03 18:26:23 -0500 |
|---|---|---|
| committer | sostler <sbostler@gmail.com> | 2010-01-03 18:26:23 -0500 |
| commit | 4b51ea0eb70699285e1b6d6432b07722c793c57a (patch) | |
| tree | 17dcf5ccb1ce946b71de9209a23a3cc04cdf2355 /static/pichat.js | |
| parent | 75a590ec89a9b7afb070331a25069e75a33ec30b (diff) | |
Work checkin
Diffstat (limited to 'static/pichat.js')
| -rwxr-xr-x | static/pichat.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/static/pichat.js b/static/pichat.js index 435dc0d..81882fe 100755 --- a/static/pichat.js +++ b/static/pichat.js @@ -35,9 +35,14 @@ function buildMessageDiv(msg) { } function buildUserDiv(user) { - return '<div class="username"><a href="/u/' + escapeHtml(user.nick) + '">' + + if (user.avatar) { + return '<div class="username"><a href="/u/' + escapeHtml(user.nick) + '">' + '<img src="' + user.avatar + '" width="50" height="50">' + escapeHtml(user.nick) + '</a></div>'; + } else { + return '<div class="username"><a href="/u/' + escapeHtml(user.nick) + '">' + + escapeHtml(user.nick) + '</a></div>'; + } } function handleMsgError(resp) { |
