fix guest login feature

This commit is contained in:
zefie
2021-08-07 19:03:07 -04:00
parent c09d0d6989
commit 95d069582b
6 changed files with 87 additions and 62 deletions

View File

@@ -29,6 +29,7 @@ class WTVRegister {
checkUsernameAvailable(username, ssid_sessions) {
var username_match = false;
this.fs.readdirSync(this.session_store_dir).forEach(file => {
if (!file.match(/.*\.json/ig)) return;
if (username_match) return;
try {
var temp_session_data_file = this.fs.readFileSync(this.session_store_dir + this.path.sep + file, 'Utf8');