Skip to content
This repository

Show the logged-in username instead of the server #150

Closed
wants to merge 1 commit into from

2 participants

Gergely Nagy David Petersen
Gergely Nagy

If we have a logged in user, show the username they logged in with,
instead of the server on the user-box on the sidebar.

There's little space left there, so adding the username separately
isn't a particularly good choice.

This fixes #149.

Signed-off-by: Gergely Nagy algernon@madhouse-project.org

Gergely Nagy algernon Show the logged-in username instead of the server
If we have a logged in user, show the username they logged in with,
instead of the server on the user-box on the sidebar.

There's little space left there, so adding the username separately
isn't a particularly good choice.

This fixes #149.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
a1d8d24
David Petersen
Owner

This is difficult, because I for one prefer to see the server in that spot. This seems like it would be something to add in the settings area(if they ever get implemented).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Jul 23, 2012
Gergely Nagy algernon Show the logged-in username instead of the server
If we have a logged in user, show the username they logged in with,
instead of the server on the user-box on the sidebar.

There's little space left there, so adding the username separately
isn't a particularly good choice.

This fixes #149.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
a1d8d24
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 2 additions and 1 deletion. Show diff stats Hide diff stats

  1. +2 1  assets/js/client.js
3  assets/js/client.js
@@ -54,6 +54,7 @@ $(function() {
54 54 });
55 55
56 56 irc.socket.on('login_success', function(data) {
  57 + irc.username = data.username;
57 58 if(data.exists){
58 59 irc.socket.emit('connect', {});
59 60 } else {
@@ -72,7 +73,7 @@ $(function() {
72 73 });
73 74
74 75 irc.socket.on('restore_connection', function(data) {
75   - irc.me = new User({nick: data.nick, server: data.server});
  76 + irc.me = new User({nick: data.nick, server: (irc.username) ? irc.username : data.server, username: irc.username});
76 77 irc.connected = true;
77 78 irc.appView.render();
78 79 irc.appView.renderUserBox();

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.