Skip to content

Commit bed18fe

Browse files
zombiyamodsyer
authored andcommitted
Fixed to display login link first
1 parent 4c684de commit bed18fe

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

github/src/main/resources/static/index.html

+6-2
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,12 @@ <h1>Login</h1>
4646
});
4747
$.get("/user", function(data) {
4848
$("#user").html(data.name);
49-
$(".unauthenticated").hide();
50-
$(".authenticated").show();
49+
if (data.name==undefined) {
50+
logout();
51+
}else{
52+
$(".unauthenticated").hide();
53+
$(".authenticated").show();
54+
}
5155
});
5256
var logout = function() {
5357
$.post("/logout", function() {

0 commit comments

Comments
 (0)