function e(e){if(!n())return;let r=t();r&&r.userId&&sessionStorage.setItem(`zxlLoginUserId`,r.userId),e()}function t(){let e=localStorage.getItem(`zxlLoginTokenInfo`);if(!e)return null;try{let t=JSON.parse(e);return!Array.isArray(t)||!t.length?null:(t.sort((e,t)=>t.timestamp-e.timestamp),t[0])}catch{return null}}function n(){let e=localStorage.getItem(`zxlLoginTokenInfo`);if(!e)return!1;try{let t=JSON.parse(e);return Array.isArray(t)}catch{return!1}}export{n,e as r,t};