add wtv-ticket store api

- fix broken session bust crap from before
- properly resume session as user when server restarted
- api available to store other things in the wtv-ticket
This commit is contained in:
zefie
2022-02-08 16:10:15 -05:00
parent d1c70c7ab1
commit bf7369431e
7 changed files with 124 additions and 37 deletions

View File

@@ -30,6 +30,7 @@ if (errpage) {
var freeUserId = ssid_sessions[socket.ssid].findFreeUserSlot(ssid_sessions[socket.ssid]);
if (freeUserId) {
userSession.user_id = freeUserId;
userSession.setSessionData("subscriber_userid", freeUserId);
userSession.setSessionData("subscriber_name", request_headers.query.display_name);
userSession.setSessionData("subscriber_username", request_headers.query.user_name);
userSession.setSessionData("registered", true);