git.gnu.io has moved to IP address 209.51.188.249 -- please double check where you are logging in.

Commit 959171ac authored by Sarven Capadisli's avatar Sarven Capadisli

Added a cookie for the nickname cookie for the login page and prefill

the input field.
parent 1f45273d
......@@ -737,6 +737,20 @@ var SN = { // StatusNet
SN.U.NewDirectMessage();
}
},
Login: function() {
if (SN.U.StatusNetInstance.Get() !== null) {
var nickname = SN.U.StatusNetInstance.Get().Nickname;
if (nickname !== null) {
$('#form_login #nickname').val(nickname);
}
}
$('#form_login').bind('submit', function() {
SN.U.StatusNetInstance.Set({Nickname: $('#form_login #nickname').val()});
return true;
});
}
}
};
......@@ -751,5 +765,8 @@ $(document).ready(function(){
if ($('#content .entity_actions').length > 0) {
SN.Init.EntityActions();
}
if ($('#form_login').length > 0) {
SN.Init.Login();
}
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment