|
|
@ -91,10 +91,12 @@ namespace FLocal.IISHandler { |
|
|
|
HttpCookie sessionCookie = this.httprequest.Cookies["session"]; |
|
|
|
HttpCookie sessionCookie = this.httprequest.Cookies["session"]; |
|
|
|
if(sessionCookie != null && sessionCookie.Value != null && sessionCookie.Value != "") { |
|
|
|
if(sessionCookie != null && sessionCookie.Value != null && sessionCookie.Value != "") { |
|
|
|
try { |
|
|
|
try { |
|
|
|
this.session = Session.LoadByKey(sessionCookie.Value); |
|
|
|
var session = Session.LoadByKey(sessionCookie.Value); |
|
|
|
|
|
|
|
var tmp = session.account; |
|
|
|
sessionCookie.Expires = DateTime.Now.AddDays(3); |
|
|
|
sessionCookie.Expires = DateTime.Now.AddDays(3); |
|
|
|
this.session.updateLastActivity(); |
|
|
|
session.updateLastActivity(); |
|
|
|
this.httpresponse.AppendCookie(sessionCookie); |
|
|
|
this.httpresponse.AppendCookie(sessionCookie); |
|
|
|
|
|
|
|
this.session = session; |
|
|
|
} catch(NotFoundInDBException) { |
|
|
|
} catch(NotFoundInDBException) { |
|
|
|
sessionCookie.Value = ""; |
|
|
|
sessionCookie.Value = ""; |
|
|
|
sessionCookie.Expires = DateTime.Now.AddDays(-1); |
|
|
|
sessionCookie.Expires = DateTime.Now.AddDays(-1); |
|
|
|